Skip to content

Commit aff6701

Browse files
author
tianqi77
committed
add more tests
1 parent 6066e9f commit aff6701

File tree

101 files changed

+46611
-5705
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

101 files changed

+46611
-5705
lines changed

Team20/Tests20/iteration3/Affects/affects_4_queries.txt

+575
Large diffs are not rendered by default.

Team20/Tests20/iteration3/Affects/affects_5_queries.txt

+52-52
Large diffs are not rendered by default.

Team20/Tests20/iteration3/Affects/affects_5_source.txt

+20-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ procedure a {
55
if (z < 3) then {
66
t = t + 1;
77
t = t * 2;
8-
call b;
8+
call b;
99
call c;
1010
} else {
1111
t = t / 2;
@@ -18,7 +18,7 @@ procedure a {
1818
read x;
1919
call c;
2020
}
21-
}
21+
}
2222

2323
}
2424

@@ -35,8 +35,18 @@ procedure b {
3535
p = p + 1;
3636
a = a + 1;
3737
} else {
38-
call d;
38+
call d;
39+
}
40+
41+
}
42+
k = k + 1;
43+
if ( x < 0) then {
44+
while (z > 0) {
45+
x = x * 5;
46+
read z;
3947
}
48+
} else {
49+
print x;
4050
}
4151
}
4252

@@ -54,4 +64,11 @@ procedure d {
5464
procedure e {
5565
call d;
5666
}
67+
68+
procedure f {
69+
call a;
70+
call b;
71+
call b;
72+
call c;
73+
}
5774

Team20/Tests20/iteration3/AffectsBip/affectsbip_2_queries.txt

+575
Large diffs are not rendered by default.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
procedure One {
2+
read i;
3+
if (i <= 0) then {
4+
i = 10;
5+
} else {
6+
i = i;
7+
}
8+
while (i >= 0) {
9+
read x;
10+
read y;
11+
read distance;
12+
k = 0;
13+
read x1;
14+
read y1;
15+
difference =
16+
(x - x1) * (x - x1) + (y - y1) * (y - y1) - distance * distance;
17+
if (difference > 0) then {
18+
print x1;
19+
print y1;
20+
} else {
21+
while (difference <= 0) {
22+
read x1;
23+
read y1;
24+
difference =
25+
(x - x1) * (x - x1) + (y - y1) * (y - y1) - distance * distance;
26+
k = k + 1;
27+
}
28+
print k;
29+
print x1;
30+
print y1;
31+
}
32+
i = i - 1;
33+
call Two;
34+
}
35+
}
36+
37+
procedure Two {
38+
if (x1 < x) then {
39+
if (y1 < y) then {
40+
i = i + 1;
41+
} else {
42+
i = i + 1;
43+
}
44+
} else {
45+
if (y1 < y) then {
46+
i = i + 1;
47+
} else {
48+
i = i;
49+
}
50+
}
51+
}

0 commit comments

Comments
 (0)