summaryrefslogtreecommitdiff
path: root/fpcsrc/tests/webtbs/tw16108.pp
blob: 470c623d2f6e16f5532027ec9014ab171e666f82 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
uses
  Math;
var
  i: longint;
  ires: longint;
  qres: int64;
begin
  randomize;
  for i:=1 to 100 do
    begin
      ires:=randomrange(-4,-7);
      if (ires<-7) or
         (ires>=-4) then
        halt(1);
      ires:=randomrange(-7,-4);
      if (ires<-7) or
         (ires>=-4) then
        halt(2);
      ires:=randomrange(10,-3);
      if (ires<-3) or
         (ires>=10) then
        halt(3);
      ires:=randomrange(-3,10);
      if (ires<-3) or
         (ires>=10) then
        halt(4);
      ires:=randomrange(5,10);
      if (ires<5) or
         (ires>=10) then
        halt(5);
      ires:=randomrange(10,5);
      if (ires<5) or
         (ires>=10) then
        halt(6);

      qres:=randomrange(low(int64)+1,low(int64)+10);
      if (qres<low(int64)+1) or
         (qres>=low(int64)+10) then
        halt(7);
      qres:=randomrange(low(int64)+10,low(int64)+1);
      if (qres<low(int64)+1) or
         (qres>=low(int64)+10) then
        halt(8);
      qres:=randomrange(int64(10),int64(-3));
      if (qres<-3) or
         (qres>=10) then
        halt(3);
      qres:=randomrange(int64(-3),int64(10));
      if (qres<-3) or
         (qres>=10) then
        halt(4);
      qres:=randomrange(int64(5),int64(10));
      if (qres<5) or
         (qres>=10) then
        halt(5);
      qres:=randomrange(int64(10),int64(5));
      if (qres<5) or
         (qres>=10) then
        halt(6);
    end;
end.