*** TEST 001 *** Translating... 1 begin 2 real x; 3 integer i; 4 i := 10000000000000000000000000; 5 x := 1.0#999 6 end Compiling... Executing... *** TEST 002 *** Translating... 1 begin 2 comment library 1; 3 real autocorrelationcoefficientnumber1; 4 autocorrelationcoefficientnumber1 := 0.0; 5 begin 6 real autocorrelationcoefficientnumber2; 7 autocorrelationcoefficientnumber2 := 1.0; 8 outreal(1, autocorrelationcoefficientnumber1 + 9 autocorrelationcoefficientnumber2 ) 10 end 11 end Compiling... Executing... 1 *** TEST 003 *** Translating... 1 l1: 2 begin 3 if 1 = 2 then 4 go to l1 5 end Compiling... Executing... *** TEST 004 *** Translating... 1 sin: cos: 2 begin 3 real sin; 4 sin := 0.0 5 end Compiling... Executing... *** TEST 005 *** Translating... 1 l1: 2 if 1 = 2 then 3 go to l1 test005.alg:2: missing bracket 'begin' test005.alg:3: one error detected on the first pass; translation terminated *** TEST 006 *** Translating... 1 begin 2 integer x, y, z; 3 x := y := z := 1.0; 4 if x < y < z then 5 end test006.alg:4: invalid use of relational operator test006.alg:5: warning: unlabelled dummy statement test006.alg:5: one error detected on the first pass; translation terminated *** TEST 007 *** Translating... 1 begin 2 3 comment library 1; 4 5 Boolean 6 assign; 7 procedure p(x); 8 real 9 x; 10 begin 11 outreal(1, x); 12 if assign then 13 x := 3.14; 14 end; 15 16 real 17 x, 18 y; 19 assign := false; 20 p(1.0); 21 x := y := 2.0; 22 p(x + y); 23 assign := true; 24 p(x); 25 p(1.0); 26 outreal(1, 1.0) 27 end Compiling... Executing... 1 4 2 1 fault: assignment to a real formal parameter called by name not possible because final actual parameter is not a variable procedure p, file test007.alg, line 13 main program, file test007.alg, line 25 *** TEST 008 *** Translating... 1 begin 2 real x, y; 3 x := y := 0.0; 4 real z; 5 end test008.alg:4: declarator `real' in invalid position test008.alg:5: warning: unlabelled dummy statement test008.alg:5: one error detected on the first pass; translation terminated *** TEST 009 *** Translating... 1 begin 2 comment a syntax pass is required to remove comments; 3 procedure p( st );comment st is a string;comment; 4 string st; ;comment dummy body; 5 p( ";comment\";\"" ); 6 begin 7 procedure q( a ) parameter comment :( b ); 8 real a, b; ;comment dummy again; 9 q( 1.0, 2.5 ); comment is the same as; 10 q( 1.0) with parameter comment:( 2.5 ); 11 end comment can include most basic symbols for 12 while then do if := begin( which are not matched; 13 end test009.alg:4: warning: unlabelled dummy statement test009.alg:7: delimiter `comment' in invalid position test009.alg:8: missing colon in parameter delimiter test009.alg:8: missing left parenthesis in parameter delimiter test009.alg:8: missing formal parameter identifier test009.alg:8: missing right parenthesis after formal parameter list test009.alg:8: missing semicolon after formal parameter part test009.alg:8: formal parameter `a' not specified test009.alg:8: specification part of procedure `q' incomplete test009.alg:8: warning: unlabelled dummy statement test009.alg:10: delimiter `comment' in invalid position test009.alg:11: missing colon in parameter delimiter test009.alg:11: missing left parenthesis in parameter delimiter test009.alg:11: warning: comment sequence following `end' contains delimiter(s) test009.alg:13: invalid use of delimiter `end' as expression operand test009.alg:13: missing right parenthesis after actual parameter list test009.alg:13: warning: unlabelled dummy statement test009.alg:13: missing `end' bracket test009.alg:13: 14 errors detected on the first pass; translation terminated *** TEST 010 *** Translating... 1 begin 2 procedure p( st, a ); string st, a; 3 ; 4 p( ";comment" )valid:( ";" ); comment could fail too few parameters; 5 end Compiling... Executing... *** TEST 011 *** Translating... 1 begin 2 real x )invalid parameter like comments:(y; 3 x := y := 0.0 4 end test011.alg:2: missing semicolon after type declaration test011.alg:4: identifier `y' not declared (see line 3) test011.alg:4: 2 errors detected on the first pass; translation terminated *** TEST 012 *** Translating... 1 begin 2 procedure q( st ) invalid parameter like comments ( a ); 3 string st; real a; ; 4 q( "az" ) also in the call( 1.0 ) 5 end test012.alg:2: missing colon in parameter delimiter test012.alg:4: warning: unlabelled dummy statement test012.alg:4: missing colon in parameter delimiter test012.alg:5: 2 errors detected on the first pass; translation terminated *** TEST 013 *** Translating... 1 begin 2 labelscannotpreceedcomments: comment should fail; 3 go to labelscannotpreceedcomments 4 end test013.alg:2: delimiter `comment' in invalid position test013.alg:4: one error detected on the first pass; translation terminated *** TEST 014 *** Translating... 1 begin 2 procedure q( st )invalid parameter comment :( a ); 3 string st; real a; ; 4 q( "str" ) az09:( 1.0 ) 5 end test014.alg:2: delimiter `comment' in invalid position test014.alg:3: missing colon in parameter delimiter test014.alg:3: missing left parenthesis in parameter delimiter test014.alg:3: missing formal parameter identifier test014.alg:3: missing right parenthesis after formal parameter list test014.alg:3: missing semicolon after formal parameter part test014.alg:3: identifier `a' missing from formal parameter list test014.alg:4: formal parameter `st' not specified test014.alg:4: specification part of procedure `q' incomplete test014.alg:4: warning: unlabelled dummy statement test014.alg:4: invalid letter string in parameter delimiter test014.alg:5: 10 errors detected on the first pass; translation terminated *** TEST 015 *** Translating... 1 begin 2 procedure q( st1 )p:( st2 ); comment ; 3 string st1, st2; ; 4 q( ";comment ) az: (";" )invalid:( "st2" ) 5 end test015.alg:4: warning: unlabelled dummy statement test015.alg:4: missing right parenthesis after actual parameter list test015.alg:4: invalid use of string test015.alg:4: string incomplete test015.alg:5: 3 errors detected on the first pass; translation terminated *** TEST 016 *** Translating... 1 begin 2 3 comment string tests; 4 5 procedure p(st); 6 string 7 st; 8 ; 9 10 p( "*string string \"nested\"\"\"\"\" begin end;" ); 11 p( " , 12 " ) 13 end test016.alg:10: warning: unlabelled dummy statement test016.alg:11: string incomplete test016.alg:12: string incomplete test016.alg:13: missing right parenthesis after actual parameter list test016.alg:13: 3 errors detected on the first pass; translation terminated *** TEST 017 *** Translating... 1 begin 2 real 3 real, 4 integer, 5 begin, 6 end; 7 real := 0.0 8 end test017.alg:3: missing simple variable identifier test017.alg:3: missing semicolon after type declaration test017.alg:7: missing simple variable identifier test017.alg:7: missing semicolon after type declaration test017.alg:8: unexpected eof test017.alg:8: missing `end' bracket test017.alg:8: 6 errors detected on the first pass; translation terminated *** TEST 018 *** Translating... 1 begin 2 real 3 a, 4 ab, 5 abc, 6 abcd, 7 abcde, 8 abcdef, 9 abcdefg, 10 abcdefgh, 11 abcdefghi, 12 abcdefghij, 13 abcdefghijk, 14 abcdefghijkl, 15 abcdefghijklm, 16 abcdefghijklmn, 17 abcdefghijklnmo, 18 abcdefghijklnmop, 19 abcdefghijklmnopq, 20 abcdefghijklnmopqr, 21 abcdefghijklmnopqrs, 22 abcdefghijklmnopqrst, 23 abcdefghijklmnopqrstu, 24 abcdefghijklmnopqrstuv, 25 abcdefghijklmnopqrstuvw, 26 abcdefghijklmnopqrstuvwx, 27 abcdefghijklmnopqrstuvwxy, 28 abcdegfhijklmnopqrstuvwxyz, 29 abcdefghijklmnpoqrstuvwxyza, 30 abcdefghijklmnopqrstuvwxyzab, 31 abcdefghijklmnopqrstuvwxyzabc, 32 abcdefghijklmnopqrstuvwxyzabcd, 33 abcdefghijklmnopqrstuvwxyzabcde, 34 abcdefghijklmnopqrstuvwxyzabcdef, 35 abcdefghijklmnopqrstuvwxyzabcdefg, 36 abcdefghijklmnopqrstuvwxyzabcdefgh, 37 abcdefghijklnmopqrstuvwxyzabcdefghi, 38 abcdefghijklmnopqrstuvwxyzabcdefghij, 39 abcdefghijklmnopqrstuvwxyzabcdefghijk, 40 abcdefghijklmnopqrstuvwxyzabcdefghijkl, 41 abcdefghijklmnopqrstuvwxyzabcdefghijklm, 42 abcdefghijklmnopqrstuvwxyzabcdefghijklmn, 43 abcdefghijklmnopqrstuvwxyzabcdefghijklmno, 44 abcdefghijklmnopqrstuvwxyzabcdefghijklmnop, 45 abcdefghijklmnopqrstuvwxyzabcdefghijklmnopq, 46 abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqr, 47 abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrs, 48 abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrst, 49 abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstu, 50 abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuv; 51 integer ac, 52 c a; 53 ac := 1 2 3 4 5 6; 54 a := 1 . 0 0 # 1 0 55 end Compiling... Executing... *** TEST 019 *** Translating... 1 begin 2 comment library 1; 3 array 4 a[1 : 3], 5 b[1 : 3, 1 : 3]; 6 real procedure sum(dim, a); 7 value 8 dim; 9 integer 10 dim; 11 array 12 a; 13 sum := 14 if dim = 1 then 15 a[1] + a[2] + a[3] 16 else 17 sum2(a); 18 19 real procedure sum2(a); 20 array 21 a; 22 sum2 := a[1, 1] + a[1, 2] + a[1, 3] + a[2, 1] + a[2, 2] + 23 a[2, 3] + a[3, 1] + a[3, 2] + a[3, 3]; 24 25 integer 26 i, 27 j; 28 for i := 1, 29 2, 30 3 do 31 begin 32 a[i] := i * i; 33 for j := 1, 34 2, 35 3 do 36 b[i, j] := a[i] + j 37 end; 38 outreal(1,sum(2, a)); 39 outreal(1,sum(1, b)) 40 end test019.alg:17: dimension of array `a' passed as actual parameter not equal to dimension of formal array `a' as implied in declaration of procedure `sum2' beginning at line 19 test019.alg:39: dimension of array `b' passed as actual parameter not equal to dimension of formal array `a' as implied in declaration of procedure `sum' beginning at line 6 test019.alg:40: 2 errors detected on the second pass; translation terminated *** TEST 020 *** Translating... 1 begin 2 comment library 1; 3 array 4 a[1 : 3], 5 b[1 : 3, 1 : 3]; 6 real procedure sum(dim, a); 7 value 8 dim; 9 integer 10 dim; 11 array 12 a; 13 sum := 14 if dim = 1 then 15 a[1] + a[2] + a[3] 16 else 17 sum2(a); 18 19 real procedure sum2(a); 20 array 21 a; 22 sum2 := a[1, 1] + a[1, 2] + a[1, 3] + a[2, 1] + a[2, 2] + 23 a[2, 3] + a[3, 1] + a[3, 2] + a[3, 3]; 24 25 integer 26 i, 27 j; 28 for i := 1, 29 2, 30 3 do 31 begin 32 a[i] := i * i; 33 for j := 1, 34 2, 35 3 do 36 b[i, j] := a[i] + j 37 end; 38 outreal(1,sum(1, a)); 39 outreal(1,sum(2, b)) 40 end test020.alg:17: dimension of array `a' passed as actual parameter not equal to dimension of formal array `a' as implied in declaration of procedure `sum2' beginning at line 19 test020.alg:39: dimension of array `b' passed as actual parameter not equal to dimension of formal array `a' as implied in declaration of procedure `sum' beginning at line 6 test020.alg:40: 2 errors detected on the second pass; translation terminated *** TEST 021 *** Translating... 1 begin 2 comment lib 1; 3 array 4 a[1 : 3], 5 b[1 : 3, 1 : 3]; 6 real procedure sum(dim, a); 7 value 8 dim; 9 integer 10 dim; 11 array 12 a; 13 sum := 14 if dim = 1 then 15 (a[1] + a[2] + a[3]) 16 else 17 (a[1, 1] + a[1, 2] + a[1, 3] + a[2, 1] + a[2, 2] 18 + a[2, 3] + a[3, 1] + a[3, 2] + a[3, 3]); 19 20 integer 21 i, 22 j; 23 for i := 1, 24 2, 25 3 do 26 begin 27 a[i] := i * i; 28 for j := 1, 29 2, 30 3 do 31 b[i, j] := a[i] + j 32 end; 33 outreal(1,sum(1, a)); 34 outreal(1,sum(2, b)); 35 end test021.alg:35: warning: unlabelled dummy statement test021.alg:17: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:17: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:17: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:17: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:18: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:18: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:18: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:18: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:18: number of subscripts in subscripted variable conflicts with earlier use of array `a' test021.alg:34: dimension of array `b' passed as actual parameter not equal to dimension of formal array `a' as implied in declaration of procedure `sum' beginning at line 6 test021.alg:35: 10 errors detected on the second pass; translation terminated *** TEST 022 *** Translating... 1 begin 2 comment lib 1; 3 procedure recursive(level, l); 4 value 5 level; 6 integer 7 level; 8 label 9 l; 10 begin 11 if level != 0 then 12 recursive(level - 1, exit) 13 else 14 go to l; 15 exit :; 16 outreal(1,level) 17 end; 18 19 recursive(10, exit); 20 exit :; 21 end Compiling... Executing... 1 2 3 4 5 6 7 8 9 10 *** TEST 023 *** Translating... 1 begin 2 comment lib5; 3 integer 4 i; 5 Boolean 6 b; 7 procedure labelbyvalue(l); 8 value 9 l; 10 label 11 l; 12 ; 13 14 procedure labelbyname(l); 15 label 16 l; 17 begin 18 i := 1; 19 if b then 20 go to l 21 end; 22 23 switch s := 24 l1, 25 l2; 26 integer procedure nottouse; 27 nottouse := sqrt( - 1); 28 29 integer procedure one; 30 one := 1; 31 32 b := false; 33 labelbyname(s[nottouse]); 34 b := true; 35 i := 2; 36 labelbyname(s[i]); 37 l1 :; 38 outreal(1,1); 39 l2 :; 40 outreal(1,2); 41 labelbyvalue(s[one]); 42 end Compiling... Executing... 1 2 *** TEST 024 *** Translating... 1 begin 2 comment lib 1; 3 integer array 4 a[1 : 9]; 5 integer 6 i, 7 s; 8 procedure dummy(a); 9 value 10 a; 11 array 12 a; 13 sum(a); 14 15 procedure sum(a); 16 array 17 a; 18 for i := 1 step 1 until 9 do 19 begin 20 s := s + a[i]; 21 a[i] := 0 22 end; 23 24 s := 0; 25 for i := 1 step 1 until 9 do 26 a[i] := i; 27 dummy(a); 28 outreal(1,s); 29 for i := 1 step 1 until 9 do 30 if a[i] != i then 31 outreal(1,i) 32 end Compiling... Executing... 45 *** TEST 025 *** Translating... 1 begin 2 3 comment lib1; 4 5 real 6 x, 7 y; 8 integer 9 i; 10 for x := #6, 11 #+6, 12 #-6, 13 .6, 14 6, 15 6.6, 16 .6#6, 17 .6#+6, 18 .6#-6, 19 6#6, 20 6#+6, 21 6#-6, 22 6.6#6, 23 6.6#+6, 24 6.6#-6 do 25 outreal(1, x); 26 outreal(1, .0000000000000000123456789123456789); 27 outreal(1, 3.1415926535897932384626433832795028841972); 28 x := y := .0000001; 29 for i := 1 step 1 until 13 do 30 begin 31 outreal(1, x); 32 outreal(1, y); 33 x := 10.0 * x; 34 y := 110 * x / 10.0 35 end 36 end Compiling... Executing... 1000000 1000000 1e-06 0.6 6 6.6 600000 600000 6e-07 6000000 6000000 6e-06 6600000 6600000 6.6e-06 1.23456789123e-17 3.14159265359 1e-07 1e-07 1e-06 1.1e-05 1e-05 0.00011 0.0001 0.0011 0.001 0.011 0.01 0.11 0.1 1.1 1 11 10 110 100 1100 1000 11000 10000 110000 100000 1100000 *** TEST 026 *** Translating... 1 begin 2 procedure p(l); 3 integer 4 l; 5 l : begin 6 real 7 a; 8 go to l; 9 l :; 10 go to ll 11 end; 12 13 p(1); 14 ll :; 15 end Compiling... Executing... *** TEST 027 *** Translating... 1 begin 2 3 comment lib 1; 4 5 integer 6 s; 7 procedure p(f, g); 8 procedure 9 f, 10 g; 11 begin 12 integer 13 x; 14 procedure r; 15 begin 16 outreal(1, s); 17 outreal(1, x) 18 end; 19 20 s := s + 1; 21 x := s; 22 if s = 1 then 23 p(f, r) 24 else 25 f(g, r) 26 end p; 27 28 procedure q(f, g); 29 procedure 30 f, 31 g; 32 begin 33 f; 34 g 35 end q; 36 37 s := 0; 38 p(q, p); 39 end Compiling... Executing... 2 1 2 2 *** TEST 028 *** Translating... 1 begin 2 3 comment lib 1; 4 5 integer 6 n1, 7 n2; 8 procedure dummy; 9 ; 10 11 procedure p(x, l); 12 value 13 x; 14 integer 15 x; 16 procedure 17 l; 18 begin 19 procedure gotol1; 20 go to l1; 21 22 if x = n1 then 23 p(x - 1, gotol1) 24 else if x = n2 then 25 l 26 else 27 p(x - 1, l); 28 l1 :; 29 outreal(1, x) 30 end p; 31 32 n1 := 4; 33 n2 := 2; 34 p(5, dummy); 35 n2 := 0; 36 p(7, dummy); 37 end Compiling... Executing... 4 5 4 5 6 7 *** TEST 029 *** Translating... 1 begin 2 3 comment lib 1; 4 5 integer 6 s; 7 procedure p(f, g); 8 procedure 9 f, 10 g; 11 begin 12 integer 13 x; 14 procedure r(f, g); 15 16 procedure f, g; 17 begin 18 outreal(1, s); 19 outreal(1, x) 20 end; 21 22 s := s + 1; 23 x := s; 24 if s = 1 then 25 p(f, r) 26 else 27 f(g, r) 28 end p; 29 30 procedure q(f, g); 31 procedure 32 f, 33 g; 34 begin 35 36 f( q, q ); 37 g( q, q) 38 end q; 39 40 s := 0; 41 p(q, p); 42 end Compiling... Executing... 2 1 2 2 *** TEST 030 *** Translating... 1 begin 2 3 comment lib 1; 4 5 integer 6 n1, 7 n2; 8 9 procedure p(x, l); 10 value 11 x; 12 integer 13 x; 14 label 15 l; 16 begin 17 18 if x = n1 then 19 p(x - 1, l1) 20 else if x = n2 then 21 go to l 22 else 23 p(x - 1, l); 24 l1 :; 25 outreal(1, x) 26 end p; 27 28 n1 := 4; 29 n2 := 2; 30 p(5, l2); 31 n2 := 0; 32 p(7, l2); 33 34 l2:; 35 end Compiling... Executing... 4 5 4 5 6 7 *** TEST 031 *** Translating... 1 begin 2 3 comment library 1; 4 integer 5 i, 6 j; 7 i := j := 0; 8 i := 9 if i = 0 then 10 11 if j = 0 then 12 1 13 else 14 2 15 else 16 3; 17 if i = 1 then 18 if j = 0 then 19 j := 2 20 else 21 j := 3 22 else 23 j := 4; 24 outreal(1, i); 25 outreal(1, j) 26 end test031.alg:11: invalid use of delimiter `if' as expression operand test031.alg:11: missing `else' delimiter test031.alg:12: missing semicolon, `else', or `end' after statement test031.alg:14: invalid use of delimiter `else' outside if statement test031.alg:16: invalid use of constant `2' test031.alg:16: invalid use of delimiter `else' outside if statement test031.alg:17: invalid use of constant `3' test031.alg:23: invalid use of delimiter `else' after if or for statement test031.alg:26: 8 errors detected on the first pass; translation terminated *** TEST 032 *** Translating... 1 begin 2 3 comment library 1; 4 integer 5 i; 6 real 7 x; 8 procedure ass(x, i); 9 real 10 x; 11 integer 12 i; 13 if i < 0 then 14 x := i + 3 15 else 16 i := 2.0 * x; 17 18 ass(x, - 1); 19 i := 2; 20 ass(x, i); 21 ass(i, i); 22 ass(i, x); 23 outreal(1, i); 24 outreal(1, x) 25 end Compiling... Executing... 8 16 *** TEST 033 *** Translating... 1 begin 2 procedure a0; 3 begin 4 procedure a1; 5 begin 6 procedure a2; 7 begin 8 procedure a3; 9 begin 10 procedure a4; 11 begin 12 procedure a5; 13 begin 14 15 end; 16 17 ; 18 end; 19 20 ; 21 end; 22 23 ; 24 end; 25 26 ; 27 end; 28 29 ; 30 end; 31 32 ; 33 end Compiling... Executing... *** TEST 034 *** Translating... 1 begin 2 real 3 a; 4 begin 5 real 6 a; 7 begin 8 real 9 a; 10 begin 11 real 12 a; 13 begin 14 real 15 a; 16 begin 17 real 18 a; 19 begin 20 real 21 a; 22 begin 23 real 24 a; 25 begin 26 real 27 a; 28 begin 29 real 30 a; 31 begin 32 real 33 a; 34 begin 35 real 36 a; 37 begin 38 real 39 a; 40 begin 41 real 42 a; 43 begin 44 real 45 a; 46 47 end 48 end 49 end 50 end 51 end 52 end 53 end 54 end 55 end 56 end 57 end 58 end 59 end 60 61 end 62 63 end Compiling... Executing... *** TEST 035 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 a0, 7 a1, 8 a2, 9 a3, 10 a4, 11 a5, 12 a6, 13 a7, 14 a8, 15 a9, 16 a10, 17 a11, 18 a12, 19 a13, 20 a14, 21 a15, 22 a16, 23 a17, 24 a18, 25 a19, 26 a20, 27 a21, 28 a22, 29 a23, 30 a24, 31 a25, 32 a26, 33 a27, 34 a28, 35 a29, 36 a30, 37 a31, 38 a32, 39 a33, 40 a34, 41 a35, 42 a36, 43 a37, 44 a38, 45 a39, 46 a40, 47 a41, 48 a42, 49 a43, 50 a44, 51 a45, 52 a46, 53 a47, 54 a48, 55 a49, 56 a50, 57 a51, 58 a52, 59 a53, 60 a54, 61 a55, 62 a56, 63 a57, 64 a58, 65 a59, 66 a60, 67 a61, 68 a62, 69 a63, 70 a64, 71 a65, 72 a66, 73 a67, 74 a68, 75 a69, 76 a70, 77 a71, 78 a72, 79 a73, 80 a74, 81 a75, 82 a76, 83 a77, 84 a78, 85 a79, 86 a80, 87 a81, 88 a82, 89 a83, 90 a84, 91 a85, 92 a86, 93 a87, 94 a88, 95 a89, 96 a90, 97 a91, 98 a92, 99 a93, 100 a94, 101 a95, 102 a96, 103 a97, 104 a98, 105 a99, 106 a100, 107 a101, 108 a102, 109 a103, 110 a104, 111 a105, 112 a106, 113 a107, 114 a108, 115 a109, 116 a110, 117 a111, 118 a112, 119 a113, 120 a114, 121 a115, 122 a116, 123 a117, 124 a118, 125 a119, 126 a120, 127 a121, 128 a122, 129 a123, 130 a124, 131 a125, 132 a126, 133 a127, 134 a128, 135 a129, 136 a130, 137 a131, 138 a132, 139 a133, 140 a134, 141 a135, 142 a136, 143 a137, 144 a138, 145 a139, 146 a140, 147 a141, 148 a142, 149 a143, 150 a144, 151 a145, 152 a146, 153 a147, 154 a148, 155 a149, 156 a150, 157 a151, 158 a152, 159 a153, 160 a154, 161 a155, 162 a156, 163 a157, 164 a158, 165 a159, 166 a160, 167 a161, 168 a162, 169 a163, 170 a164, 171 a165, 172 a166, 173 a167, 174 a168, 175 a169, 176 a170, 177 a171, 178 a172, 179 a173, 180 a174, 181 a175, 182 a176, 183 a177, 184 a178, 185 a179, 186 a180, 187 a181, 188 a182, 189 a183, 190 a184, 191 a185, 192 a186, 193 a187, 194 a188, 195 a189, 196 a190, 197 a191, 198 a192, 199 a193, 200 a194, 201 a195, 202 a196, 203 a197, 204 a198, 205 a199, 206 a200, 207 a201, 208 a202, 209 a203, 210 a204, 211 a205, 212 a206, 213 a207, 214 a208, 215 a209, 216 a210, 217 a211, 218 a212, 219 a213, 220 a214, 221 a215, 222 a216, 223 a217, 224 a218, 225 a219, 226 a220, 227 a221, 228 a222, 229 a223, 230 a224, 231 a225, 232 a226, 233 a227, 234 a228, 235 a229, 236 a230, 237 a231, 238 a232, 239 a233, 240 a234, 241 a235, 242 a236, 243 a237, 244 a238, 245 a239, 246 a240, 247 a241, 248 a242, 249 a243, 250 a244, 251 a245, 252 a246, 253 a247, 254 a248, 255 a249, 256 a250, 257 a251, 258 a252, 259 a253, 260 a254, 261 a255, 262 a256, 263 a257, 264 a258, 265 a259, 266 a260, 267 a261, 268 a262, 269 a263, 270 a264, 271 a265, 272 a266, 273 a267, 274 a268, 275 a269, 276 a270, 277 a271, 278 a272, 279 a273, 280 a274, 281 a275, 282 a276, 283 a277, 284 a278, 285 a279, 286 a280, 287 a281, 288 a282, 289 a283, 290 a284, 291 a285, 292 a286, 293 a287, 294 a288, 295 a289, 296 a290, 297 a291, 298 a292, 299 a293, 300 a294, 301 a295, 302 a296, 303 a297, 304 a298, 305 a299; 306 a0 := 1.0; 307 a1 := 1.0; 308 a2 := 1.0; 309 a3 := 1.0; 310 a4 := 1.0; 311 a5 := 1.0; 312 a6 := 1.0; 313 a7 := 1.0; 314 a8 := 1.0; 315 a9 := 1.0; 316 a10 := 1.0; 317 a11 := 1.0; 318 a12 := 1.0; 319 a13 := 1.0; 320 a14 := 1.0; 321 a15 := 1.0; 322 a16 := 1.0; 323 a17 := 1.0; 324 a18 := 1.0; 325 a19 := 1.0; 326 a20 := 1.0; 327 a21 := 1.0; 328 a22 := 1.0; 329 a23 := 1.0; 330 a24 := 1.0; 331 a25 := 1.0; 332 a26 := 1.0; 333 a27 := 1.0; 334 a28 := 1.0; 335 a29 := 1.0; 336 a30 := 1.0; 337 a31 := 1.0; 338 a32 := 1.0; 339 a33 := 1.0; 340 a34 := 1.0; 341 a35 := 1.0; 342 a36 := 1.0; 343 a37 := 1.0; 344 a38 := 1.0; 345 a39 := 1.0; 346 a40 := 1.0; 347 a41 := 1.0; 348 a42 := 1.0; 349 a43 := 1.0; 350 a44 := 1.0; 351 a45 := 1.0; 352 a46 := 1.0; 353 a47 := 1.0; 354 a48 := 1.0; 355 a49 := 1.0; 356 a50 := 1.0; 357 a51 := 1.0; 358 a52 := 1.0; 359 a53 := 1.0; 360 a54 := 1.0; 361 a55 := 1.0; 362 a56 := 1.0; 363 a57 := 1.0; 364 a58 := 1.0; 365 a59 := 1.0; 366 a60 := 1.0; 367 a61 := 1.0; 368 a62 := 1.0; 369 a63 := 1.0; 370 a64 := 1.0; 371 a65 := 1.0; 372 a66 := 1.0; 373 a67 := 1.0; 374 a68 := 1.0; 375 a69 := 1.0; 376 a70 := 1.0; 377 a71 := 1.0; 378 a72 := 1.0; 379 a73 := 1.0; 380 a74 := 1.0; 381 a75 := 1.0; 382 a76 := 1.0; 383 a77 := 1.0; 384 a78 := 1.0; 385 a79 := 1.0; 386 a80 := 1.0; 387 a81 := 1.0; 388 a82 := 1.0; 389 a83 := 1.0; 390 a84 := 1.0; 391 a85 := 1.0; 392 a86 := 1.0; 393 a87 := 1.0; 394 a88 := 1.0; 395 a89 := 1.0; 396 a90 := 1.0; 397 a91 := 1.0; 398 a92 := 1.0; 399 a93 := 1.0; 400 a94 := 1.0; 401 a95 := 1.0; 402 a96 := 1.0; 403 a97 := 1.0; 404 a98 := 1.0; 405 a99 := 1.0; 406 a100 := 1.0; 407 a101 := 1.0; 408 a102 := 1.0; 409 a103 := 1.0; 410 a104 := 1.0; 411 a105 := 1.0; 412 a106 := 1.0; 413 a107 := 1.0; 414 a108 := 1.0; 415 a109 := 1.0; 416 a110 := 1.0; 417 a111 := 1.0; 418 a112 := 1.0; 419 a113 := 1.0; 420 a114 := 1.0; 421 a115 := 1.0; 422 a116 := 1.0; 423 a117 := 1.0; 424 a118 := 1.0; 425 a119 := 1.0; 426 a120 := 1.0; 427 a121 := 1.0; 428 a122 := 1.0; 429 a123 := 1.0; 430 a124 := 1.0; 431 a125 := 1.0; 432 a126 := 1.0; 433 a127 := 1.0; 434 a128 := 1.0; 435 a129 := 1.0; 436 a130 := 1.0; 437 a131 := 1.0; 438 a132 := 1.0; 439 a133 := 1.0; 440 a134 := 1.0; 441 a135 := 1.0; 442 a136 := 1.0; 443 a137 := 1.0; 444 a138 := 1.0; 445 a139 := 1.0; 446 a140 := 1.0; 447 a141 := 1.0; 448 a142 := 1.0; 449 a143 := 1.0; 450 a144 := 1.0; 451 a145 := 1.0; 452 a146 := 1.0; 453 a147 := 1.0; 454 a148 := 1.0; 455 a149 := 1.0; 456 a150 := 1.0; 457 a151 := 1.0; 458 a152 := 1.0; 459 a153 := 1.0; 460 a154 := 1.0; 461 a155 := 1.0; 462 a156 := 1.0; 463 a157 := 1.0; 464 a158 := 1.0; 465 a159 := 1.0; 466 a160 := 1.0; 467 a161 := 1.0; 468 a162 := 1.0; 469 a163 := 1.0; 470 a164 := 1.0; 471 a165 := 1.0; 472 a166 := 1.0; 473 a167 := 1.0; 474 a168 := 1.0; 475 a169 := 1.0; 476 a170 := 1.0; 477 a171 := 1.0; 478 a172 := 1.0; 479 a173 := 1.0; 480 a174 := 1.0; 481 a175 := 1.0; 482 a176 := 1.0; 483 a177 := 1.0; 484 a178 := 1.0; 485 a179 := 1.0; 486 a180 := 1.0; 487 a181 := 1.0; 488 a182 := 1.0; 489 a183 := 1.0; 490 a184 := 1.0; 491 a185 := 1.0; 492 a186 := 1.0; 493 a187 := 1.0; 494 a188 := 1.0; 495 a189 := 1.0; 496 a190 := 1.0; 497 a191 := 1.0; 498 a192 := 1.0; 499 a193 := 1.0; 500 a194 := 1.0; 501 a195 := 1.0; 502 a196 := 1.0; 503 a197 := 1.0; 504 a198 := 1.0; 505 a199 := 1.0; 506 a200 := 1.0; 507 a201 := 1.0; 508 a202 := 1.0; 509 a203 := 1.0; 510 a204 := 1.0; 511 a205 := 1.0; 512 a206 := 1.0; 513 a207 := 1.0; 514 a208 := 1.0; 515 a209 := 1.0; 516 a210 := 1.0; 517 a211 := 1.0; 518 a212 := 1.0; 519 a213 := 1.0; 520 a214 := 1.0; 521 a215 := 1.0; 522 a216 := 1.0; 523 a217 := 1.0; 524 a218 := 1.0; 525 a219 := 1.0; 526 a220 := 1.0; 527 a221 := 1.0; 528 a222 := 1.0; 529 a223 := 1.0; 530 a224 := 1.0; 531 a225 := 1.0; 532 a226 := 1.0; 533 a227 := 1.0; 534 a228 := 1.0; 535 a229 := 1.0; 536 a230 := 1.0; 537 a231 := 1.0; 538 a232 := 1.0; 539 a233 := 1.0; 540 a234 := 1.0; 541 a235 := 1.0; 542 a236 := 1.0; 543 a237 := 1.0; 544 a238 := 1.0; 545 a239 := 1.0; 546 a240 := 1.0; 547 a241 := 1.0; 548 a242 := 1.0; 549 a243 := 1.0; 550 a244 := 1.0; 551 a245 := 1.0; 552 a246 := 1.0; 553 a247 := 1.0; 554 a248 := 1.0; 555 a249 := 1.0; 556 a250 := 1.0; 557 a251 := 1.0; 558 a252 := 1.0; 559 a253 := 1.0; 560 a254 := 1.0; 561 a255 := 1.0; 562 a256 := 1.0; 563 a257 := 1.0; 564 a258 := 1.0; 565 a259 := 1.0; 566 a260 := 1.0; 567 a261 := 1.0; 568 a262 := 1.0; 569 a263 := 1.0; 570 a264 := 1.0; 571 a265 := 1.0; 572 a266 := 1.0; 573 a267 := 1.0; 574 a268 := 1.0; 575 a269 := 1.0; 576 a270 := 1.0; 577 a271 := 1.0; 578 a272 := 1.0; 579 a273 := 1.0; 580 a274 := 1.0; 581 a275 := 1.0; 582 a276 := 1.0; 583 a277 := 1.0; 584 a278 := 1.0; 585 a279 := 1.0; 586 a280 := 1.0; 587 a281 := 1.0; 588 a282 := 1.0; 589 a283 := 1.0; 590 a284 := 1.0; 591 a285 := 1.0; 592 a286 := 1.0; 593 a287 := 1.0; 594 a288 := 1.0; 595 a289 := 1.0; 596 a290 := 1.0; 597 a291 := 1.0; 598 a292 := 1.0; 599 a293 := 1.0; 600 a294 := 1.0; 601 a295 := 1.0; 602 a296 := 1.0; 603 a297 := 1.0; 604 a298 := 1.0; 605 a299 := 1.0; 606 outreal(1, a0 + a1 + a2 + a3 + a4 + a5 + a6 + a7 + a8 + a9 + a10 607 + a11 + a12 + a13 + a14 + a15 + a16 + a17 + a18 + a19 + 608 a20 + a21 + a22 + a23 + a24 + a25 + a26 + a27 + a28 + 609 a29 + a30 + a31 + a32 + a33 + a34 + a35 + a36 + a37 + 610 a38 + a39 + a40 + a41 + a42 + a43 + a44 + a45 + a46 + 611 a47 + a48 + a49 + a50 + a51 + a52 + a53 + a54 + a55 + 612 a56 + a57 + a58 + a59 + a60 + a61 + a62 + a63 + a64 + 613 a65 + a66 + a67 + a68 + a69 + a70 + a71 + a72 + a73 + 614 a74 + a75 + a76 + a77 + a78 + a79 + a80 + a81 + a82 + 615 a83 + a84 + a85 + a86 + a87 + a88 + a89 + a90 + a91 + 616 a92 + a93 + a94 + a95 + a96 + a97 + a98 + a99 + a100 + 617 a101 + a102 + a103 + a104 + a105 + a106 + a107 + a108 + 618 a109 + a110 + a111 + a112 + a113 + a114 + a115 + a116 + 619 a117 + a118 + a119 + a120 + a121 + a122 + a123 + a124 + 620 a125 + a126 + a127 + a128 + a129 + a130 + a131 + a132 + 621 a133 + a134 + a135 + a136 + a137 + a138 + a139 + a140 + 622 a141 + a142 + a143 + a144 + a145 + a146 + a147 + a148 + 623 a149 + a150 + a151 + a152 + a153 + a154 + a155 + a156 + 624 a157 + a158 + a159 + a160 + a161 + a162 + a163 + a164 + 625 a165 + a166 + a167 + a168 + a169 + a170 + a171 + a172 + 626 a173 + a174 + a175 + a176 + a177 + a178 + a179 + a180 + 627 a181 + a182 + a183 + a184 + a185 + a186 + a187 + a188 + 628 a189 + a190 + a191 + a192 + a193 + a194 + a195 + a196 + 629 a197 + a198 + a199 + a200 + a201 + a202 + a203 + a204 + 630 a205 + a206 + a207 + a208 + a209 + a210 + a211 + a212 + 631 a213 + a214 + a215 + a216 + a217 + a218 + a219 + a220 + 632 a221 + a222 + a223 + a224 + a225 + a226 + a227 + a228 + 633 a229 + a230 + a231 + a232 + a233 + a234 + a235 + a236 + 634 a237 + a238 + a239 + a240 + a241 + a242 + a243 + a244 + 635 a245 + a246 + a247 + a248 + a249 + a250 + a251 + a252 + 636 a253 + a254 + a255 + a256 + a257 + a258 + a259 + a260 + 637 a261 + a262 + a263 + a264 + a265 + a266 + a267 + a268 + 638 a269 + a270 + a271 + a272 + a273 + a274 + a275 + a276 + 639 a277 + a278 + a279 + a280 + a281 + a282 + a283 + a284 + 640 a285 + a286 + a287 + a288 + a289 + a290 + a291 + a292 + 641 a293 + a294 + a295 + a296 + a297 + a298 + a299); 642 end Compiling... Executing... 300 *** TEST 036 *** Translating... 1 begin 2 3 comment library 1; 4 5 array 6 a0, 7 a1, 8 a2, 9 a3, 10 a4, 11 a5, 12 a6, 13 a7, 14 a8, 15 a9, 16 a10, 17 a11, 18 a12, 19 a13, 20 a14, 21 a15, 22 a16, 23 a17, 24 a18, 25 a19, 26 a20, 27 a21, 28 a22, 29 a23, 30 a24, 31 a25, 32 a26, 33 a27, 34 a28, 35 a29, 36 a30, 37 a31, 38 a32, 39 a33, 40 a34, 41 a35, 42 a36, 43 a37, 44 a38, 45 a39, 46 a40, 47 a41, 48 a42, 49 a43, 50 a44, 51 a45, 52 a46, 53 a47, 54 a48, 55 a49, 56 a50, 57 a51, 58 a52, 59 a53, 60 a54, 61 a55, 62 a56, 63 a57, 64 a58, 65 a59[1 : 10]; 66 a0[1] := 1.0; 67 a1[1] := 1.0; 68 a2[1] := 1.0; 69 a3[1] := 1.0; 70 a4[1] := 1.0; 71 a5[1] := 1.0; 72 a6[1] := 1.0; 73 a7[1] := 1.0; 74 a8[1] := 1.0; 75 a9[1] := 1.0; 76 a10[1] := 1.0; 77 a11[1] := 1.0; 78 a12[1] := 1.0; 79 a13[1] := 1.0; 80 a14[1] := 1.0; 81 a15[1] := 1.0; 82 a16[1] := 1.0; 83 a17[1] := 1.0; 84 a18[1] := 1.0; 85 a19[1] := 1.0; 86 a20[1] := 1.0; 87 a21[1] := 1.0; 88 a22[1] := 1.0; 89 a23[1] := 1.0; 90 a24[1] := 1.0; 91 a25[1] := 1.0; 92 a26[1] := 1.0; 93 a27[1] := 1.0; 94 a28[1] := 1.0; 95 a29[1] := 1.0; 96 a30[1] := 1.0; 97 a31[1] := 1.0; 98 a32[1] := 1.0; 99 a33[1] := 1.0; 100 a34[1] := 1.0; 101 a35[1] := 1.0; 102 a36[1] := 1.0; 103 a37[1] := 1.0; 104 a38[1] := 1.0; 105 a39[1] := 1.0; 106 a40[1] := 1.0; 107 a41[1] := 1.0; 108 a42[1] := 1.0; 109 a43[1] := 1.0; 110 a44[1] := 1.0; 111 a45[1] := 1.0; 112 a46[1] := 1.0; 113 a47[1] := 1.0; 114 a48[1] := 1.0; 115 a49[1] := 1.0; 116 a50[1] := 1.0; 117 a51[1] := 1.0; 118 a52[1] := 1.0; 119 a53[1] := 1.0; 120 a54[1] := 1.0; 121 a55[1] := 1.0; 122 a56[1] := 1.0; 123 a57[1] := 1.0; 124 a58[1] := 1.0; 125 a59[1] := 1.0; 126 outreal(1, a0[1] + a1[1] + a2[1] + a3[1] + a4[1] + a5[1] + a6[1] 127 + a7[1] + a8[1] + a9[1] + a10[1] + a11[1] + a12[1] + 128 a13[1] + a14[1] + a15[1] + a16[1] + a17[1] + a18[1] + 129 a19[1] + a20[1] + a21[1] + a22[1] + a23[1] + a24[1] + 130 a25[1] + a26[1] + a27[1] + a28[1] + a29[1] + a30[1] + 131 a31[1] + a32[1] + a33[1] + a34[1] + a35[1] + a36[1] + 132 a37[1] + a38[1] + a39[1] + a40[1] + a41[1] + a42[1] + 133 a43[1] + a44[1] + a45[1] + a46[1] + a47[1] + a48[1] + 134 a49[1] + a50[1] + a51[1] + a52[1] + a53[1] + a54[1] + 135 a55[1] + a56[1] + a57[1] + a58[1] + a59[1]); 136 end Compiling... Executing... 60 *** TEST 037 *** Translating... 1 begin 2 integer 3 a0, 4 a1, 5 a2, 6 a3, 7 a4, 8 a5, 9 a6, 10 a7, 11 a8, 12 a9, 13 a10, 14 a11; 15 integer 16 sum; 17 18 comment library 1; 19 20 21 sum := 0; 22 for a0 := 1, 23 2 do 24 begin 25 sum := sum + 1; 26 for a1 := 1, 27 2 do 28 begin 29 sum := sum + 1; 30 for a2 := 1, 31 2 do 32 begin 33 sum := sum + 1; 34 for a3 := 1, 35 2 do 36 begin 37 sum := sum + 1; 38 for a4 := 1, 39 2 do 40 begin 41 sum := sum + 1; 42 for a5 := 1, 43 2 do 44 begin 45 sum := sum + 1; 46 for a6 := 1, 47 2 do 48 begin 49 sum := sum + 1; 50 for a7 := 1, 51 2 do 52 begin 53 sum := sum + 1; 54 for a8 := 1, 55 2 do 56 begin 57 sum := sum + 1; 58 for a9 := 1, 59 2 do 60 begin 61 sum := sum + 1; 62 for a10 := 1, 63 2 do 64 begin 65 sum := sum + 1; 66 for a11 := 1, 67 2 do 68 begin 69 sum := sum + 1; 70 end 71 end 72 end 73 end 74 end 75 end 76 end 77 end 78 end 79 end 80 end 81 end; 82 83 outreal(1, sum); 84 85 end Compiling... Executing... 8190 *** TEST 038 *** Translating... 1 begin 2 comment library 1; 3 integer 4 i, 5 j, 6 sum; 7 8 i := 1; 9 j := 2; 10 sum := 0; 11 if i > j then 12 begin 13 14 end 15 else 16 begin 17 sum := sum + 1; 18 if i > j then 19 begin 20 21 end 22 else 23 begin 24 sum := sum + 1; 25 if i > j then 26 begin 27 28 end 29 else 30 begin 31 sum := sum + 1; 32 if i > j then 33 begin 34 35 end 36 else 37 begin 38 sum := sum + 1; 39 if i > j then 40 begin 41 42 end 43 else 44 begin 45 sum := sum + 1; 46 if i > j then 47 begin 48 49 end 50 else 51 begin 52 sum := sum + 1; 53 if i > j then 54 begin 55 56 end 57 else 58 begin 59 sum := sum + 1; 60 if i > j then 61 begin 62 63 end 64 else 65 begin 66 sum := sum + 1; 67 if i > j then 68 begin 69 70 end 71 else 72 begin 73 sum := sum + 1; 74 if i > j then 75 begin 76 77 end 78 else 79 begin 80 sum := sum + 1; 81 if i > j then 82 begin 83 84 end 85 else 86 begin 87 sum := sum + 1; 88 if i > j then 89 begin 90 91 end 92 else 93 begin 94 sum := sum + 1; 95 if i > j then 96 begin 97 98 end 99 else 100 begin 101 sum := sum + 1; 102 if i > j then 103 begin 104 105 end 106 else 107 begin 108 sum := sum + 1; 109 if i > j then 110 begin 111 112 end 113 else 114 begin 115 sum := sum + 1; 116 if i > j then 117 begin 118 119 end 120 else 121 begin 122 sum := sum + 1; 123 if i > j then 124 begin 125 126 end 127 else 128 begin 129 sum := sum + 1; 130 if i > j then 131 begin 132 133 end 134 else 135 begin 136 sum := sum + 1; 137 if i > j then 138 begin 139 140 end 141 else 142 begin 143 sum := sum + 1; 144 if i > j then 145 begin 146 147 end 148 else 149 begin 150 sum := sum + 1; 151 if i > j then 152 begin 153 154 end 155 else 156 begin 157 sum := sum + 1; 158 if i > j then 159 begin 160 161 end 162 else 163 begin 164 sum := sum + 1; 165 if i > j then 166 begin 167 168 end 169 else 170 begin 171 sum := sum + 1; 172 if i > j then 173 begin 174 175 end 176 else 177 begin 178 sum := sum + 1; 179 end 180 end 181 end 182 end 183 end 184 end 185 end 186 end 187 end 188 end 189 end 190 end 191 end 192 end 193 end 194 end 195 end 196 end 197 end 198 end 199 end 200 end 201 end 202 end; 203 204 outreal(1, sum); 205 206 207 end Compiling... Executing... 24 *** TEST 039 *** Translating... 1 begin 2 comment library 1; 3 integer 4 i, 5 j, 6 sum; 7 i := 1; 8 j := 2; 9 sum := 1 + (if i > j then 0 else (if i > j then 0 else 10 (if i > j then 0 else (if i > j then 0 else (if i 11 > j then 0 else (if i > j then 0 else (if i > j 12 then 0 else (if i > j then 0 else (if i > j then 13 0 else 1))))))))); 14 outreal(1, sum); 15 end Compiling... Executing... 2 *** TEST 040 *** Translating... 1 begin 2 3 comment library 1; 4 5 switch ss := 6 a0, 7 a1, 8 a2, 9 a3, 10 a4, 11 a5, 12 a6, 13 a7, 14 a8, 15 a9, 16 a10, 17 a11, 18 a12, 19 a13, 20 a14, 21 a15, 22 a16, 23 a17, 24 a18, 25 a19, 26 a20, 27 a21, 28 a22, 29 a23, 30 a24, 31 a25, 32 a26, 33 a27, 34 a28, 35 a29, 36 a30, 37 a31, 38 a32, 39 a33, 40 a34, 41 a35, 42 a36, 43 a37, 44 a38, 45 a39, 46 a40, 47 a41, 48 a42, 49 a43, 50 a44, 51 a45, 52 a46, 53 a47, 54 a48, 55 a49, 56 a50, 57 a51, 58 a52, 59 a53, 60 a54, 61 a55, 62 a56, 63 a57, 64 a58, 65 a59, 66 a60, 67 a61, 68 a62, 69 a63, 70 a64, 71 a65, 72 a66, 73 a67, 74 a68, 75 a69, 76 a70, 77 a71, 78 a72, 79 a73, 80 a74, 81 a75, 82 a76, 83 a77, 84 a78, 85 a79, 86 a80, 87 a81, 88 a82, 89 a83, 90 a84, 91 a85, 92 a86, 93 a87, 94 a88, 95 a89, 96 a90, 97 a91, 98 a92, 99 a93, 100 a94, 101 a95, 102 a96, 103 a97, 104 a98, 105 a99, 106 a100, 107 a101, 108 a102, 109 a103, 110 a104, 111 a105, 112 a106, 113 a107, 114 a108, 115 a109, 116 a110, 117 a111, 118 a112, 119 a113, 120 a114, 121 a115, 122 a116, 123 a117, 124 a118, 125 a119, 126 a120, 127 a121, 128 a122, 129 a123, 130 a124, 131 a125, 132 a126, 133 a127, 134 a128, 135 a129, 136 a130, 137 a131, 138 a132, 139 a133, 140 a134, 141 a135, 142 a136, 143 a137, 144 a138, 145 a139, 146 a140, 147 a141, 148 a142, 149 a143, 150 a144, 151 a145, 152 a146, 153 a147, 154 a148, 155 a149, 156 a150, 157 a151, 158 a152, 159 a153, 160 a154, 161 a155, 162 a156, 163 a157, 164 a158, 165 a159, 166 a160, 167 a161, 168 a162, 169 a163, 170 a164, 171 a165, 172 a166, 173 a167, 174 a168, 175 a169, 176 a170, 177 a171, 178 a172, 179 a173, 180 a174, 181 a175, 182 a176, 183 a177, 184 a178, 185 a179, 186 a180, 187 a181, 188 a182, 189 a183, 190 a184, 191 a185, 192 a186, 193 a187, 194 a188, 195 a189, 196 a190, 197 a191, 198 a192, 199 a193, 200 a194, 201 a195, 202 a196, 203 a197, 204 a198, 205 a199, 206 a200, 207 a201, 208 a202, 209 a203, 210 a204, 211 a205, 212 a206, 213 a207, 214 a208, 215 a209, 216 a210, 217 a211, 218 a212, 219 a213, 220 a214, 221 a215, 222 a216, 223 a217, 224 a218, 225 a219, 226 a220, 227 a221, 228 a222, 229 a223, 230 a224, 231 a225, 232 a226, 233 a227, 234 a228, 235 a229, 236 a230, 237 a231, 238 a232, 239 a233, 240 a234, 241 a235, 242 a236, 243 a237, 244 a238, 245 a239, 246 a240, 247 a241, 248 a242, 249 a243, 250 a244, 251 a245, 252 a246, 253 a247, 254 a248, 255 a249, 256 a250, 257 a251, 258 a252, 259 a253, 260 a254, 261 a255, 262 a256, 263 a257, 264 a258, 265 a259, 266 a260, 267 a261, 268 a262, 269 a263, 270 a264, 271 a265, 272 a266, 273 a267, 274 a268, 275 a269, 276 a270, 277 a271, 278 a272, 279 a273, 280 a274, 281 a275, 282 a276, 283 a277, 284 a278, 285 a279, 286 a280, 287 a281, 288 a282, 289 a283, 290 a284, 291 a285, 292 a286, 293 a287, 294 a288, 295 a289, 296 a290, 297 a291, 298 a292, 299 a293, 300 a294, 301 a295, 302 a296, 303 a297, 304 a298, 305 a299; 306 integer 307 sum; 308 sum := 1; 309 a0 :; 310 sum := sum + 1; 311 go to ss[sum]; 312 a1 :; 313 sum := sum + 1; 314 go to ss[sum]; 315 a2 :; 316 sum := sum + 1; 317 go to ss[sum]; 318 a3 :; 319 sum := sum + 1; 320 go to ss[sum]; 321 a4 :; 322 sum := sum + 1; 323 go to ss[sum]; 324 a5 :; 325 sum := sum + 1; 326 go to ss[sum]; 327 a6 :; 328 sum := sum + 1; 329 go to ss[sum]; 330 a7 :; 331 sum := sum + 1; 332 go to ss[sum]; 333 a8 :; 334 sum := sum + 1; 335 go to ss[sum]; 336 a9 :; 337 sum := sum + 1; 338 go to ss[sum]; 339 a10 :; 340 sum := sum + 1; 341 go to ss[sum]; 342 a11 :; 343 sum := sum + 1; 344 go to ss[sum]; 345 a12 :; 346 sum := sum + 1; 347 go to ss[sum]; 348 a13 :; 349 sum := sum + 1; 350 go to ss[sum]; 351 a14 :; 352 sum := sum + 1; 353 go to ss[sum]; 354 a15 :; 355 sum := sum + 1; 356 go to ss[sum]; 357 a16 :; 358 sum := sum + 1; 359 go to ss[sum]; 360 a17 :; 361 sum := sum + 1; 362 go to ss[sum]; 363 a18 :; 364 sum := sum + 1; 365 go to ss[sum]; 366 a19 :; 367 sum := sum + 1; 368 go to ss[sum]; 369 a20 :; 370 sum := sum + 1; 371 go to ss[sum]; 372 a21 :; 373 sum := sum + 1; 374 go to ss[sum]; 375 a22 :; 376 sum := sum + 1; 377 go to ss[sum]; 378 a23 :; 379 sum := sum + 1; 380 go to ss[sum]; 381 a24 :; 382 sum := sum + 1; 383 go to ss[sum]; 384 a25 :; 385 sum := sum + 1; 386 go to ss[sum]; 387 a26 :; 388 sum := sum + 1; 389 go to ss[sum]; 390 a27 :; 391 sum := sum + 1; 392 go to ss[sum]; 393 a28 :; 394 sum := sum + 1; 395 go to ss[sum]; 396 a29 :; 397 sum := sum + 1; 398 go to ss[sum]; 399 a30 :; 400 sum := sum + 1; 401 go to ss[sum]; 402 a31 :; 403 sum := sum + 1; 404 go to ss[sum]; 405 a32 :; 406 sum := sum + 1; 407 go to ss[sum]; 408 a33 :; 409 sum := sum + 1; 410 go to ss[sum]; 411 a34 :; 412 sum := sum + 1; 413 go to ss[sum]; 414 a35 :; 415 sum := sum + 1; 416 go to ss[sum]; 417 a36 :; 418 sum := sum + 1; 419 go to ss[sum]; 420 a37 :; 421 sum := sum + 1; 422 go to ss[sum]; 423 a38 :; 424 sum := sum + 1; 425 go to ss[sum]; 426 a39 :; 427 sum := sum + 1; 428 go to ss[sum]; 429 a40 :; 430 sum := sum + 1; 431 go to ss[sum]; 432 a41 :; 433 sum := sum + 1; 434 go to ss[sum]; 435 a42 :; 436 sum := sum + 1; 437 go to ss[sum]; 438 a43 :; 439 sum := sum + 1; 440 go to ss[sum]; 441 a44 :; 442 sum := sum + 1; 443 go to ss[sum]; 444 a45 :; 445 sum := sum + 1; 446 go to ss[sum]; 447 a46 :; 448 sum := sum + 1; 449 go to ss[sum]; 450 a47 :; 451 sum := sum + 1; 452 go to ss[sum]; 453 a48 :; 454 sum := sum + 1; 455 go to ss[sum]; 456 a49 :; 457 sum := sum + 1; 458 go to ss[sum]; 459 a50 :; 460 sum := sum + 1; 461 go to ss[sum]; 462 a51 :; 463 sum := sum + 1; 464 go to ss[sum]; 465 a52 :; 466 sum := sum + 1; 467 go to ss[sum]; 468 a53 :; 469 sum := sum + 1; 470 go to ss[sum]; 471 a54 :; 472 sum := sum + 1; 473 go to ss[sum]; 474 a55 :; 475 sum := sum + 1; 476 go to ss[sum]; 477 a56 :; 478 sum := sum + 1; 479 go to ss[sum]; 480 a57 :; 481 sum := sum + 1; 482 go to ss[sum]; 483 a58 :; 484 sum := sum + 1; 485 go to ss[sum]; 486 a59 :; 487 sum := sum + 1; 488 go to ss[sum]; 489 a60 :; 490 sum := sum + 1; 491 go to ss[sum]; 492 a61 :; 493 sum := sum + 1; 494 go to ss[sum]; 495 a62 :; 496 sum := sum + 1; 497 go to ss[sum]; 498 a63 :; 499 sum := sum + 1; 500 go to ss[sum]; 501 a64 :; 502 sum := sum + 1; 503 go to ss[sum]; 504 a65 :; 505 sum := sum + 1; 506 go to ss[sum]; 507 a66 :; 508 sum := sum + 1; 509 go to ss[sum]; 510 a67 :; 511 sum := sum + 1; 512 go to ss[sum]; 513 a68 :; 514 sum := sum + 1; 515 go to ss[sum]; 516 a69 :; 517 sum := sum + 1; 518 go to ss[sum]; 519 a70 :; 520 sum := sum + 1; 521 go to ss[sum]; 522 a71 :; 523 sum := sum + 1; 524 go to ss[sum]; 525 a72 :; 526 sum := sum + 1; 527 go to ss[sum]; 528 a73 :; 529 sum := sum + 1; 530 go to ss[sum]; 531 a74 :; 532 sum := sum + 1; 533 go to ss[sum]; 534 a75 :; 535 sum := sum + 1; 536 go to ss[sum]; 537 a76 :; 538 sum := sum + 1; 539 go to ss[sum]; 540 a77 :; 541 sum := sum + 1; 542 go to ss[sum]; 543 a78 :; 544 sum := sum + 1; 545 go to ss[sum]; 546 a79 :; 547 sum := sum + 1; 548 go to ss[sum]; 549 a80 :; 550 sum := sum + 1; 551 go to ss[sum]; 552 a81 :; 553 sum := sum + 1; 554 go to ss[sum]; 555 a82 :; 556 sum := sum + 1; 557 go to ss[sum]; 558 a83 :; 559 sum := sum + 1; 560 go to ss[sum]; 561 a84 :; 562 sum := sum + 1; 563 go to ss[sum]; 564 a85 :; 565 sum := sum + 1; 566 go to ss[sum]; 567 a86 :; 568 sum := sum + 1; 569 go to ss[sum]; 570 a87 :; 571 sum := sum + 1; 572 go to ss[sum]; 573 a88 :; 574 sum := sum + 1; 575 go to ss[sum]; 576 a89 :; 577 sum := sum + 1; 578 go to ss[sum]; 579 a90 :; 580 sum := sum + 1; 581 go to ss[sum]; 582 a91 :; 583 sum := sum + 1; 584 go to ss[sum]; 585 a92 :; 586 sum := sum + 1; 587 go to ss[sum]; 588 a93 :; 589 sum := sum + 1; 590 go to ss[sum]; 591 a94 :; 592 sum := sum + 1; 593 go to ss[sum]; 594 a95 :; 595 sum := sum + 1; 596 go to ss[sum]; 597 a96 :; 598 sum := sum + 1; 599 go to ss[sum]; 600 a97 :; 601 sum := sum + 1; 602 go to ss[sum]; 603 a98 :; 604 sum := sum + 1; 605 go to ss[sum]; 606 a99 :; 607 sum := sum + 1; 608 go to ss[sum]; 609 a100 :; 610 sum := sum + 1; 611 go to ss[sum]; 612 a101 :; 613 sum := sum + 1; 614 go to ss[sum]; 615 a102 :; 616 sum := sum + 1; 617 go to ss[sum]; 618 a103 :; 619 sum := sum + 1; 620 go to ss[sum]; 621 a104 :; 622 sum := sum + 1; 623 go to ss[sum]; 624 a105 :; 625 sum := sum + 1; 626 go to ss[sum]; 627 a106 :; 628 sum := sum + 1; 629 go to ss[sum]; 630 a107 :; 631 sum := sum + 1; 632 go to ss[sum]; 633 a108 :; 634 sum := sum + 1; 635 go to ss[sum]; 636 a109 :; 637 sum := sum + 1; 638 go to ss[sum]; 639 a110 :; 640 sum := sum + 1; 641 go to ss[sum]; 642 a111 :; 643 sum := sum + 1; 644 go to ss[sum]; 645 a112 :; 646 sum := sum + 1; 647 go to ss[sum]; 648 a113 :; 649 sum := sum + 1; 650 go to ss[sum]; 651 a114 :; 652 sum := sum + 1; 653 go to ss[sum]; 654 a115 :; 655 sum := sum + 1; 656 go to ss[sum]; 657 a116 :; 658 sum := sum + 1; 659 go to ss[sum]; 660 a117 :; 661 sum := sum + 1; 662 go to ss[sum]; 663 a118 :; 664 sum := sum + 1; 665 go to ss[sum]; 666 a119 :; 667 sum := sum + 1; 668 go to ss[sum]; 669 a120 :; 670 sum := sum + 1; 671 go to ss[sum]; 672 a121 :; 673 sum := sum + 1; 674 go to ss[sum]; 675 a122 :; 676 sum := sum + 1; 677 go to ss[sum]; 678 a123 :; 679 sum := sum + 1; 680 go to ss[sum]; 681 a124 :; 682 sum := sum + 1; 683 go to ss[sum]; 684 a125 :; 685 sum := sum + 1; 686 go to ss[sum]; 687 a126 :; 688 sum := sum + 1; 689 go to ss[sum]; 690 a127 :; 691 sum := sum + 1; 692 go to ss[sum]; 693 a128 :; 694 sum := sum + 1; 695 go to ss[sum]; 696 a129 :; 697 sum := sum + 1; 698 go to ss[sum]; 699 a130 :; 700 sum := sum + 1; 701 go to ss[sum]; 702 a131 :; 703 sum := sum + 1; 704 go to ss[sum]; 705 a132 :; 706 sum := sum + 1; 707 go to ss[sum]; 708 a133 :; 709 sum := sum + 1; 710 go to ss[sum]; 711 a134 :; 712 sum := sum + 1; 713 go to ss[sum]; 714 a135 :; 715 sum := sum + 1; 716 go to ss[sum]; 717 a136 :; 718 sum := sum + 1; 719 go to ss[sum]; 720 a137 :; 721 sum := sum + 1; 722 go to ss[sum]; 723 a138 :; 724 sum := sum + 1; 725 go to ss[sum]; 726 a139 :; 727 sum := sum + 1; 728 go to ss[sum]; 729 a140 :; 730 sum := sum + 1; 731 go to ss[sum]; 732 a141 :; 733 sum := sum + 1; 734 go to ss[sum]; 735 a142 :; 736 sum := sum + 1; 737 go to ss[sum]; 738 a143 :; 739 sum := sum + 1; 740 go to ss[sum]; 741 a144 :; 742 sum := sum + 1; 743 go to ss[sum]; 744 a145 :; 745 sum := sum + 1; 746 go to ss[sum]; 747 a146 :; 748 sum := sum + 1; 749 go to ss[sum]; 750 a147 :; 751 sum := sum + 1; 752 go to ss[sum]; 753 a148 :; 754 sum := sum + 1; 755 go to ss[sum]; 756 a149 :; 757 sum := sum + 1; 758 go to ss[sum]; 759 a150 :; 760 sum := sum + 1; 761 go to ss[sum]; 762 a151 :; 763 sum := sum + 1; 764 go to ss[sum]; 765 a152 :; 766 sum := sum + 1; 767 go to ss[sum]; 768 a153 :; 769 sum := sum + 1; 770 go to ss[sum]; 771 a154 :; 772 sum := sum + 1; 773 go to ss[sum]; 774 a155 :; 775 sum := sum + 1; 776 go to ss[sum]; 777 a156 :; 778 sum := sum + 1; 779 go to ss[sum]; 780 a157 :; 781 sum := sum + 1; 782 go to ss[sum]; 783 a158 :; 784 sum := sum + 1; 785 go to ss[sum]; 786 a159 :; 787 sum := sum + 1; 788 go to ss[sum]; 789 a160 :; 790 sum := sum + 1; 791 go to ss[sum]; 792 a161 :; 793 sum := sum + 1; 794 go to ss[sum]; 795 a162 :; 796 sum := sum + 1; 797 go to ss[sum]; 798 a163 :; 799 sum := sum + 1; 800 go to ss[sum]; 801 a164 :; 802 sum := sum + 1; 803 go to ss[sum]; 804 a165 :; 805 sum := sum + 1; 806 go to ss[sum]; 807 a166 :; 808 sum := sum + 1; 809 go to ss[sum]; 810 a167 :; 811 sum := sum + 1; 812 go to ss[sum]; 813 a168 :; 814 sum := sum + 1; 815 go to ss[sum]; 816 a169 :; 817 sum := sum + 1; 818 go to ss[sum]; 819 a170 :; 820 sum := sum + 1; 821 go to ss[sum]; 822 a171 :; 823 sum := sum + 1; 824 go to ss[sum]; 825 a172 :; 826 sum := sum + 1; 827 go to ss[sum]; 828 a173 :; 829 sum := sum + 1; 830 go to ss[sum]; 831 a174 :; 832 sum := sum + 1; 833 go to ss[sum]; 834 a175 :; 835 sum := sum + 1; 836 go to ss[sum]; 837 a176 :; 838 sum := sum + 1; 839 go to ss[sum]; 840 a177 :; 841 sum := sum + 1; 842 go to ss[sum]; 843 a178 :; 844 sum := sum + 1; 845 go to ss[sum]; 846 a179 :; 847 sum := sum + 1; 848 go to ss[sum]; 849 a180 :; 850 sum := sum + 1; 851 go to ss[sum]; 852 a181 :; 853 sum := sum + 1; 854 go to ss[sum]; 855 a182 :; 856 sum := sum + 1; 857 go to ss[sum]; 858 a183 :; 859 sum := sum + 1; 860 go to ss[sum]; 861 a184 :; 862 sum := sum + 1; 863 go to ss[sum]; 864 a185 :; 865 sum := sum + 1; 866 go to ss[sum]; 867 a186 :; 868 sum := sum + 1; 869 go to ss[sum]; 870 a187 :; 871 sum := sum + 1; 872 go to ss[sum]; 873 a188 :; 874 sum := sum + 1; 875 go to ss[sum]; 876 a189 :; 877 sum := sum + 1; 878 go to ss[sum]; 879 a190 :; 880 sum := sum + 1; 881 go to ss[sum]; 882 a191 :; 883 sum := sum + 1; 884 go to ss[sum]; 885 a192 :; 886 sum := sum + 1; 887 go to ss[sum]; 888 a193 :; 889 sum := sum + 1; 890 go to ss[sum]; 891 a194 :; 892 sum := sum + 1; 893 go to ss[sum]; 894 a195 :; 895 sum := sum + 1; 896 go to ss[sum]; 897 a196 :; 898 sum := sum + 1; 899 go to ss[sum]; 900 a197 :; 901 sum := sum + 1; 902 go to ss[sum]; 903 a198 :; 904 sum := sum + 1; 905 go to ss[sum]; 906 a199 :; 907 sum := sum + 1; 908 go to ss[sum]; 909 a200 :; 910 sum := sum + 1; 911 go to ss[sum]; 912 a201 :; 913 sum := sum + 1; 914 go to ss[sum]; 915 a202 :; 916 sum := sum + 1; 917 go to ss[sum]; 918 a203 :; 919 sum := sum + 1; 920 go to ss[sum]; 921 a204 :; 922 sum := sum + 1; 923 go to ss[sum]; 924 a205 :; 925 sum := sum + 1; 926 go to ss[sum]; 927 a206 :; 928 sum := sum + 1; 929 go to ss[sum]; 930 a207 :; 931 sum := sum + 1; 932 go to ss[sum]; 933 a208 :; 934 sum := sum + 1; 935 go to ss[sum]; 936 a209 :; 937 sum := sum + 1; 938 go to ss[sum]; 939 a210 :; 940 sum := sum + 1; 941 go to ss[sum]; 942 a211 :; 943 sum := sum + 1; 944 go to ss[sum]; 945 a212 :; 946 sum := sum + 1; 947 go to ss[sum]; 948 a213 :; 949 sum := sum + 1; 950 go to ss[sum]; 951 a214 :; 952 sum := sum + 1; 953 go to ss[sum]; 954 a215 :; 955 sum := sum + 1; 956 go to ss[sum]; 957 a216 :; 958 sum := sum + 1; 959 go to ss[sum]; 960 a217 :; 961 sum := sum + 1; 962 go to ss[sum]; 963 a218 :; 964 sum := sum + 1; 965 go to ss[sum]; 966 a219 :; 967 sum := sum + 1; 968 go to ss[sum]; 969 a220 :; 970 sum := sum + 1; 971 go to ss[sum]; 972 a221 :; 973 sum := sum + 1; 974 go to ss[sum]; 975 a222 :; 976 sum := sum + 1; 977 go to ss[sum]; 978 a223 :; 979 sum := sum + 1; 980 go to ss[sum]; 981 a224 :; 982 sum := sum + 1; 983 go to ss[sum]; 984 a225 :; 985 sum := sum + 1; 986 go to ss[sum]; 987 a226 :; 988 sum := sum + 1; 989 go to ss[sum]; 990 a227 :; 991 sum := sum + 1; 992 go to ss[sum]; 993 a228 :; 994 sum := sum + 1; 995 go to ss[sum]; 996 a229 :; 997 sum := sum + 1; 998 go to ss[sum]; 999 a230 :; 1000 sum := sum + 1; 1001 go to ss[sum]; 1002 a231 :; 1003 sum := sum + 1; 1004 go to ss[sum]; 1005 a232 :; 1006 sum := sum + 1; 1007 go to ss[sum]; 1008 a233 :; 1009 sum := sum + 1; 1010 go to ss[sum]; 1011 a234 :; 1012 sum := sum + 1; 1013 go to ss[sum]; 1014 a235 :; 1015 sum := sum + 1; 1016 go to ss[sum]; 1017 a236 :; 1018 sum := sum + 1; 1019 go to ss[sum]; 1020 a237 :; 1021 sum := sum + 1; 1022 go to ss[sum]; 1023 a238 :; 1024 sum := sum + 1; 1025 go to ss[sum]; 1026 a239 :; 1027 sum := sum + 1; 1028 go to ss[sum]; 1029 a240 :; 1030 sum := sum + 1; 1031 go to ss[sum]; 1032 a241 :; 1033 sum := sum + 1; 1034 go to ss[sum]; 1035 a242 :; 1036 sum := sum + 1; 1037 go to ss[sum]; 1038 a243 :; 1039 sum := sum + 1; 1040 go to ss[sum]; 1041 a244 :; 1042 sum := sum + 1; 1043 go to ss[sum]; 1044 a245 :; 1045 sum := sum + 1; 1046 go to ss[sum]; 1047 a246 :; 1048 sum := sum + 1; 1049 go to ss[sum]; 1050 a247 :; 1051 sum := sum + 1; 1052 go to ss[sum]; 1053 a248 :; 1054 sum := sum + 1; 1055 go to ss[sum]; 1056 a249 :; 1057 sum := sum + 1; 1058 go to ss[sum]; 1059 a250 :; 1060 sum := sum + 1; 1061 go to ss[sum]; 1062 a251 :; 1063 sum := sum + 1; 1064 go to ss[sum]; 1065 a252 :; 1066 sum := sum + 1; 1067 go to ss[sum]; 1068 a253 :; 1069 sum := sum + 1; 1070 go to ss[sum]; 1071 a254 :; 1072 sum := sum + 1; 1073 go to ss[sum]; 1074 a255 :; 1075 sum := sum + 1; 1076 go to ss[sum]; 1077 a256 :; 1078 sum := sum + 1; 1079 go to ss[sum]; 1080 a257 :; 1081 sum := sum + 1; 1082 go to ss[sum]; 1083 a258 :; 1084 sum := sum + 1; 1085 go to ss[sum]; 1086 a259 :; 1087 sum := sum + 1; 1088 go to ss[sum]; 1089 a260 :; 1090 sum := sum + 1; 1091 go to ss[sum]; 1092 a261 :; 1093 sum := sum + 1; 1094 go to ss[sum]; 1095 a262 :; 1096 sum := sum + 1; 1097 go to ss[sum]; 1098 a263 :; 1099 sum := sum + 1; 1100 go to ss[sum]; 1101 a264 :; 1102 sum := sum + 1; 1103 go to ss[sum]; 1104 a265 :; 1105 sum := sum + 1; 1106 go to ss[sum]; 1107 a266 :; 1108 sum := sum + 1; 1109 go to ss[sum]; 1110 a267 :; 1111 sum := sum + 1; 1112 go to ss[sum]; 1113 a268 :; 1114 sum := sum + 1; 1115 go to ss[sum]; 1116 a269 :; 1117 sum := sum + 1; 1118 go to ss[sum]; 1119 a270 :; 1120 sum := sum + 1; 1121 go to ss[sum]; 1122 a271 :; 1123 sum := sum + 1; 1124 go to ss[sum]; 1125 a272 :; 1126 sum := sum + 1; 1127 go to ss[sum]; 1128 a273 :; 1129 sum := sum + 1; 1130 go to ss[sum]; 1131 a274 :; 1132 sum := sum + 1; 1133 go to ss[sum]; 1134 a275 :; 1135 sum := sum + 1; 1136 go to ss[sum]; 1137 a276 :; 1138 sum := sum + 1; 1139 go to ss[sum]; 1140 a277 :; 1141 sum := sum + 1; 1142 go to ss[sum]; 1143 a278 :; 1144 sum := sum + 1; 1145 go to ss[sum]; 1146 a279 :; 1147 sum := sum + 1; 1148 go to ss[sum]; 1149 a280 :; 1150 sum := sum + 1; 1151 go to ss[sum]; 1152 a281 :; 1153 sum := sum + 1; 1154 go to ss[sum]; 1155 a282 :; 1156 sum := sum + 1; 1157 go to ss[sum]; 1158 a283 :; 1159 sum := sum + 1; 1160 go to ss[sum]; 1161 a284 :; 1162 sum := sum + 1; 1163 go to ss[sum]; 1164 a285 :; 1165 sum := sum + 1; 1166 go to ss[sum]; 1167 a286 :; 1168 sum := sum + 1; 1169 go to ss[sum]; 1170 a287 :; 1171 sum := sum + 1; 1172 go to ss[sum]; 1173 a288 :; 1174 sum := sum + 1; 1175 go to ss[sum]; 1176 a289 :; 1177 sum := sum + 1; 1178 go to ss[sum]; 1179 a290 :; 1180 sum := sum + 1; 1181 go to ss[sum]; 1182 a291 :; 1183 sum := sum + 1; 1184 go to ss[sum]; 1185 a292 :; 1186 sum := sum + 1; 1187 go to ss[sum]; 1188 a293 :; 1189 sum := sum + 1; 1190 go to ss[sum]; 1191 a294 :; 1192 sum := sum + 1; 1193 go to ss[sum]; 1194 a295 :; 1195 sum := sum + 1; 1196 go to ss[sum]; 1197 a296 :; 1198 sum := sum + 1; 1199 go to ss[sum]; 1200 a297 :; 1201 sum := sum + 1; 1202 go to ss[sum]; 1203 a298 :; 1204 sum := sum + 1; 1205 go to ss[sum]; 1206 a299 :; 1207 sum := sum + 1; 1208 outreal(1, sum); 1209 end Compiling... Executing... 301 *** TEST 041 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer procedure p(a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, 6 a10, a11, a12, a13, a14, a15, a16, a17, a18, a19, a20, 7 a21, a22, a23, a24, a25, a26, a27, a28, a29, a30, a31, 8 a32, a33, a34, a35, a36, a37, a38, a39, a40, a41, a42, 9 a43, a44, a45, a46, a47, a48, a49, a50, a51, a52, a53, 10 a54, a55, a56, a57, a58, a59); 11 value 12 a0, 13 a1, 14 a2, 15 a3, 16 a4, 17 a5, 18 a6, 19 a7, 20 a8, 21 a9, 22 a10, 23 a11, 24 a12, 25 a13, 26 a14, 27 a15, 28 a16, 29 a17, 30 a18, 31 a19, 32 a20, 33 a21, 34 a22, 35 a23, 36 a24, 37 a25, 38 a26, 39 a27, 40 a28, 41 a29, 42 a30, 43 a31, 44 a32, 45 a33, 46 a34, 47 a35, 48 a36, 49 a37, 50 a38, 51 a39, 52 a40, 53 a41, 54 a42, 55 a43, 56 a44, 57 a45, 58 a46, 59 a47, 60 a48, 61 a49, 62 a50, 63 a51, 64 a52, 65 a53, 66 a54, 67 a55, 68 a56, 69 a57, 70 a58, 71 a59; 72 integer 73 a0, 74 a1, 75 a2, 76 a3, 77 a4, 78 a5, 79 a6, 80 a7, 81 a8, 82 a9, 83 a10, 84 a11, 85 a12, 86 a13, 87 a14, 88 a15, 89 a16, 90 a17, 91 a18, 92 a19, 93 a20, 94 a21, 95 a22, 96 a23, 97 a24, 98 a25, 99 a26, 100 a27, 101 a28, 102 a29, 103 a30, 104 a31, 105 a32, 106 a33, 107 a34, 108 a35, 109 a36, 110 a37, 111 a38, 112 a39, 113 a40, 114 a41, 115 a42, 116 a43, 117 a44, 118 a45, 119 a46, 120 a47, 121 a48, 122 a49, 123 a50, 124 a51, 125 a52, 126 a53, 127 a54, 128 a55, 129 a56, 130 a57, 131 a58, 132 a59; 133 p := a0 + a1 + a2 + a3 + a4 + a5 + a6 + a7 + a8 + a9 + 134 a10 + a11 + a12 + a13 + a14 + a15 + a16 + a17 + 135 a18 + a19 + a20 + a21 + a22 + a23 + a24 + a25 + 136 a26 + a27 + a28 + a29 + a30 + a31 + a32 + a33 + 137 a34 + a35 + a36 + a37 + a38 + a39 + a40 + a41 + 138 a42 + a43 + a44 + a45 + a46 + a47 + a48 + a49 + 139 a50 + a51 + a52 + a53 + a54 + a55 + a56 + a57 + 140 a58 + a59; 141 142 outreal(1, p(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 143 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 144 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 145 1, 1, 1, 1, 1, 1, 1)); 146 end Compiling... Executing... 60 *** TEST 042 *** Translating... 1 begin 2 3 comment library 1; 4 5 array 6 a[1 : 2, 1 : 2, 1 : 2, 1 : 2, 1 : 2, 1 : 2, 1 : 2, 1 : 7 2, 1 : 2, 1 : 2, 1 : 2, 1 : 2]; 8 a[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1] := 1.0; 9 outreal(1, a[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]); 10 end test042.alg:7: array dimension exceeds allowable maximum test042.alg:8: number of subscripts exceeds allowable maximum test042.alg:9: number of subscripts exceeds allowable maximum test042.alg:10: warning: unlabelled dummy statement test042.alg:10: 3 errors detected on the first pass; translation terminated *** TEST 043 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 a0, 7 a1, 8 a2, 9 a3, 10 a4, 11 a5, 12 a6, 13 a7, 14 a8, 15 a9, 16 a10, 17 a11, 18 a12, 19 a13, 20 a14; 21 real 22 sum; 23 a0 := 1.0; 24 a1 := 1.0; 25 a2 := 1.0; 26 a3 := 1.0; 27 a4 := 1.0; 28 a5 := 1.0; 29 a6 := 1.0; 30 a7 := 1.0; 31 a8 := 1.0; 32 a9 := 1.0; 33 a10 := 1.0; 34 a11 := 1.0; 35 a12 := 1.0; 36 a13 := 1.0; 37 a14 := 1.0; 38 sum := a0 + (a1 + (a2 + (a3 + (a4 + (a5 + (a6 + (a7 + (a8 + (a9 39 + (a10 + (a11 + (a12 + (a13 + (a14)))))))))))))); 40 outreal(1, sum); 41 end Compiling... Executing... 15 *** TEST 044 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 a0, 7 a1, 8 a2, 9 a3, 10 a4, 11 a5, 12 a6, 13 a7, 14 a8, 15 a9, 16 a10, 17 a11, 18 a12, 19 a13, 20 a14; 21 real 22 sum; 23 a0 := 1.0; 24 a1 := 1.0; 25 a2 := 1.0; 26 a3 := 1.0; 27 a4 := 1.0; 28 a5 := 1.0; 29 a6 := 1.0; 30 a7 := 1.0; 31 a8 := 1.0; 32 a9 := 1.0; 33 a10 := 1.0; 34 a11 := 1.0; 35 a12 := 1.0; 36 a13 := 1.0; 37 a14 := 1.0; 38 sum := 2.0 * a0 + .5 * (2.0 * a1 + .5 * (2.0 * a2 + .5 * (2.0 39 * a3 + .5 * (2.0 * a4 + .5 * (2.0 * a5 + .5 * (2.0 * a6 40 + .5 * (2.0 * a7 + .5 * (2.0 * a8 + .5 * (2.0 * a9 + .5 41 * (2.0 * a10 + .5 * (2.0 * a11 + .5 * (2.0 * a12 + .5 * 42 (2.0 * a13 + .5 * (a14)))))))))))))); 43 outreal(1, sum); 44 end Compiling... Executing... 3.99981689453 *** TEST 045 *** Translating... 1 begin 2 3 comment library 5; 4 5 real 6 x; 7 x := 8.4; 8 outreal(1, 9 sqrt(sqrt(sqrt(sqrt(sqrt(sqrt(sqrt(sqrt(sqrt(x^9))))))))) 10 ); 11 end Compiling... Executing... 1.03811889747 *** TEST 046 *** Translating... 1 begin 2 integer 3 i, 4 j; 5 i := 1; 6 j := 2; 7 l1 :; 8 go to 9 if i > j then 10 l1 11 else if i > j then 12 l1 13 else if i > j then 14 l1 15 else if i > j then 16 l1 17 else if i > j then 18 l1 19 else if i > j then 20 l1 21 else 22 l2; 23 l2 :; 24 end Compiling... Executing... *** TEST 047 *** Translating... 1 begin 2 a0 :; 3 a1 :; 4 a2 :; 5 a3 :; 6 a4 :; 7 a5 :; 8 end Compiling... Executing... *** TEST 048 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 sum; 7 sum := 0; 8 begin 9 sum := sum + 1; 10 begin 11 sum := sum + 1; 12 begin 13 sum := sum + 1; 14 begin 15 sum := sum + 1; 16 begin 17 sum := sum + 1; 18 begin 19 sum := sum + 1; 20 begin 21 sum := sum + 1; 22 begin 23 sum := sum + 1; 24 begin 25 sum := sum + 1; 26 begin 27 sum := sum + 1; 28 begin 29 sum := sum + 1; 30 begin 31 sum := sum + 1; 32 begin 33 sum := sum + 1; 34 begin 35 sum := sum + 1; 36 begin 37 sum := sum + 1; 38 begin 39 sum := sum + 1; 40 begin 41 sum := sum + 1; 42 begin 43 sum := sum + 1; 44 begin 45 sum := sum + 1; 46 begin 47 sum := sum + 1; 48 begin 49 sum := sum + 1; 50 begin 51 sum := sum + 1; 52 begin 53 sum := sum + 1; 54 begin 55 sum := sum + 1; 56 end 57 end 58 end 59 end 60 end 61 end 62 end 63 end 64 end 65 end 66 end 67 end 68 end 69 end 70 end 71 end 72 end 73 end 74 end 75 end 76 end 77 end 78 end 79 end; 80 outreal(1, sum); 81 end Compiling... Executing... 24 *** TEST 049 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 a0, 7 a1, 8 a2, 9 a3, 10 a4, 11 a5, 12 a6, 13 a7, 14 a8, 15 a9, 16 a10, 17 a11, 18 a12, 19 a13, 20 a14; 21 a0 := a1 := a2 := a3 := a4 := a5 := a6 := a7 := a8 := 22 a9 := a10 := a11 := a12 := a13 := a14 := 1.0; 23 outreal(1, a0 + a1 + a2 + a3 + a4 + a5 + a6 + a7 + a8 + a9 + a10 24 + a11 + a12 + a13 + a14); 25 end Compiling... Executing... 15 *** TEST 050 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i, 7 sum; 8 sum := 0; 9 for i := 1, 10 i + 1, 11 i + 1, 12 i + 1, 13 i + 1, 14 i + 1, 15 i + 1, 16 i + 1, 17 i + 1, 18 i + 1, 19 i + 1, 20 i + 1, 21 i + 1, 22 i + 1, 23 i + 1, 24 i + 1, 25 i + 1, 26 i + 1, 27 i + 1, 28 i + 1, 29 i + 1, 30 i + 1, 31 i + 1, 32 i + 1, 33 i + 1, 34 i + 1, 35 i + 1, 36 i + 1, 37 i + 1, 38 i + 1, 39 i + 1, 40 i + 1, 41 i + 1, 42 i + 1, 43 i + 1, 44 i + 1, 45 i + 1, 46 i + 1, 47 i + 1, 48 i + 1, 49 i + 1, 50 i + 1, 51 i + 1, 52 i + 1, 53 i + 1, 54 i + 1, 55 i + 1, 56 i + 1, 57 i + 1, 58 i + 1, 59 i + 1, 60 i + 1, 61 i + 1, 62 i + 1, 63 i + 1, 64 i + 1, 65 i + 1, 66 i + 1, 67 i + 1, 68 i + 1 do 69 sum := sum + i; 70 outreal(1, sum); 71 end Compiling... Executing... 1830 *** TEST 051 *** Translating... 1 begin 2 3 comment library 1; 4 5 array 6 a0[1 : 10], 7 a1[1 : 10], 8 a2[1 : 10], 9 a3[1 : 10], 10 a4[1 : 10], 11 a5[1 : 10], 12 a6[1 : 10], 13 a7[1 : 10], 14 a8[1 : 10], 15 a9[1 : 10], 16 a10[1 : 10], 17 a11[1 : 10], 18 a12[1 : 10], 19 a13[1 : 10], 20 a14[1 : 10], 21 a15[1 : 10], 22 a16[1 : 10], 23 a17[1 : 10], 24 a18[1 : 10], 25 a19[1 : 10], 26 a20[1 : 10], 27 a21[1 : 10], 28 a22[1 : 10], 29 a23[1 : 10], 30 a24[1 : 10], 31 a25[1 : 10], 32 a26[1 : 10], 33 a27[1 : 10], 34 a28[1 : 10], 35 a29[1 : 10], 36 a30[1 : 10], 37 a31[1 : 10], 38 a32[1 : 10], 39 a33[1 : 10], 40 a34[1 : 10], 41 a35[1 : 10], 42 a36[1 : 10], 43 a37[1 : 10], 44 a38[1 : 10], 45 a39[1 : 10], 46 a40[1 : 10], 47 a41[1 : 10], 48 a42[1 : 10], 49 a43[1 : 10], 50 a44[1 : 10], 51 a45[1 : 10], 52 a46[1 : 10], 53 a47[1 : 10], 54 a48[1 : 10], 55 a49[1 : 10], 56 a50[1 : 10], 57 a51[1 : 10], 58 a52[1 : 10], 59 a53[1 : 10], 60 a54[1 : 10], 61 a55[1 : 10], 62 a56[1 : 10], 63 a57[1 : 10], 64 a58[1 : 10], 65 a59[1 : 10]; 66 a0[1] := 1.0; 67 a1[1] := 1.0; 68 a2[1] := 1.0; 69 a3[1] := 1.0; 70 a4[1] := 1.0; 71 a5[1] := 1.0; 72 a6[1] := 1.0; 73 a7[1] := 1.0; 74 a8[1] := 1.0; 75 a9[1] := 1.0; 76 a10[1] := 1.0; 77 a11[1] := 1.0; 78 a12[1] := 1.0; 79 a13[1] := 1.0; 80 a14[1] := 1.0; 81 a15[1] := 1.0; 82 a16[1] := 1.0; 83 a17[1] := 1.0; 84 a18[1] := 1.0; 85 a19[1] := 1.0; 86 a20[1] := 1.0; 87 a21[1] := 1.0; 88 a22[1] := 1.0; 89 a23[1] := 1.0; 90 a24[1] := 1.0; 91 a25[1] := 1.0; 92 a26[1] := 1.0; 93 a27[1] := 1.0; 94 a28[1] := 1.0; 95 a29[1] := 1.0; 96 a30[1] := 1.0; 97 a31[1] := 1.0; 98 a32[1] := 1.0; 99 a33[1] := 1.0; 100 a34[1] := 1.0; 101 a35[1] := 1.0; 102 a36[1] := 1.0; 103 a37[1] := 1.0; 104 a38[1] := 1.0; 105 a39[1] := 1.0; 106 a40[1] := 1.0; 107 a41[1] := 1.0; 108 a42[1] := 1.0; 109 a43[1] := 1.0; 110 a44[1] := 1.0; 111 a45[1] := 1.0; 112 a46[1] := 1.0; 113 a47[1] := 1.0; 114 a48[1] := 1.0; 115 a49[1] := 1.0; 116 a50[1] := 1.0; 117 a51[1] := 1.0; 118 a52[1] := 1.0; 119 a53[1] := 1.0; 120 a54[1] := 1.0; 121 a55[1] := 1.0; 122 a56[1] := 1.0; 123 a57[1] := 1.0; 124 a58[1] := 1.0; 125 a59[1] := 1.0; 126 outreal(1, a0[1] + a1[1] + a2[1] + a3[1] + a4[1] + a5[1] + a6[1] 127 + a7[1] + a8[1] + a9[1] + a10[1] + a11[1] + a12[1] + 128 a13[1] + a14[1] + a15[1] + a16[1] + a17[1] + a18[1] + 129 a19[1] + a20[1] + a21[1] + a22[1] + a23[1] + a24[1] + 130 a25[1] + a26[1] + a27[1] + a28[1] + a29[1] + a30[1] + 131 a31[1] + a32[1] + a33[1] + a34[1] + a35[1] + a36[1] + 132 a37[1] + a38[1] + a39[1] + a40[1] + a41[1] + a42[1] + 133 a43[1] + a44[1] + a45[1] + a46[1] + a47[1] + a48[1] + 134 a49[1] + a50[1] + a51[1] + a52[1] + a53[1] + a54[1] + 135 a55[1] + a56[1] + a57[1] + a58[1] + a59[1]); 136 end Compiling... Executing... 60 *** TEST 052 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer procedure iabs(i); 6 value 7 i; 8 integer 9 i; 10 iabs := 11 if i < 0 then 12 - i 13 else 14 i; 15 16 integer 17 i, 18 j, 19 k; 20 i := j := k := 1; 21 begin 22 array 23 a[(if iabs(j * k % i) > 3 * i - k then - 60 else 1) : 24 (if iabs(j * k % i) > 3 * i - k then - 60 else 1) 25 * 3.0 - 1.6 + 10.2], 26 a2[(if iabs(j * k % i) > 3 * i - k then - 60 else 1) 27 * 3.0 - 1.6 - 4 : (if iabs(j * k % i) > 3 * i - k 28 then - 60 else 1), (if iabs(j * k % i) > 3 * i - k 29 then - 60 else 1) * 3.0 - 1.6 - 4 : (if iabs(j * k 30 % i) > 3 * i - k then - 60 else 1)]; 31 Boolean 32 b; 33 switch s := 34 l1, 35 if (if iabs(j * k % i) > 3 * i - k then - 60 else 1) 36 > 6 then l1 else l2, 37 l2; 38 a[(if iabs(j * k % i) > 3 * i - k then - 60 else 1)] := 39 a2[(if iabs(j * k % i) > 3 * i - k then - 60 else 1), 40 (if iabs(j * k % i) > 3 * i - k then - 60 else 1)] 41 := (if iabs(j * k % i) > 3 * i - k then - 60 else 1) 42 * 3.0 - 1.6; 43 b := (if iabs(j * k % i) > 3 * i - k then - 60 else 1) > 44 6; 45 l1 :; 46 go to 47 if (if iabs(j * k % i) > 3 * i - k then - 60 else 1) 48 > 6 then 49 l1 50 else 51 l2; 52 l2 :; 53 for i := 1 step (if iabs(j * k % i) > 3 * i - k then - 54 60 else 1) until (if iabs(j * k % i) > 3 * i - k 55 then - 60 else 1) do 56 a[i] := (if iabs(j * k % i) > 3 * i - k then - 60 57 else 1) * 3.0 - 1.6; 58 for i := (if iabs(j * k % i) > 3 * i - k then - 60 else 59 1), 60 (if iabs(j * k % i) > 3 * i - k then - 60 else 1) + 61 1, 62 (if iabs(j * k % i) > 3 * i - k then - 60 else 1) + 10 63 do 64 a[i] := (if iabs(j * k % i) > 3 * i - k then - 60 65 else 1); 66 if (if iabs(j * k % i) > 3 * i - k then - 60 else 1) > 6 67 then 68 go to s[(if iabs(j * k % i) > 3 * i - k then - 60 69 else 1) * 3.0 - 1.6] 70 else 71 for i := (if iabs(j * k % i) > 3 * i - k then - 60 72 else 1) step 10 until (if iabs(j * k % i) > 3 73 * i - k then - 60 else 1) - 1 do 74 for j := (if iabs(j * k % i) > 3 * i - k then - 75 60 else 1) while (if iabs(j * k % i) > 3 76 * i - k then - 60 else 1) > 6 do 77 ; 78 i := iabs((if iabs(j * k % i) > 3 * i - k then - 60 else 79 1)); 80 j := iabs((if iabs(j * k % i) > 3 * i - k then - 60 else 81 1) * 3.0 - 1.6); 82 outreal(1, i + j + (if iabs(j * k % i) > 3 * i - k then - 83 60 else 1) * 3.0 - 1.6 + (if iabs(j * k % i) > 3 * i - 84 k then - 60 else 1) + a[1] + a2[1, 1]); 85 end 86 end Compiling... Executing... 6.8 *** TEST 053 *** Translating... 1 begin 2 3 comment library5; 4 5 integer 6 i, 7 j; 8 for i := - 2, 9 - 1, 10 1, 11 2 do 12 for j := - 2 step 1 until 2 do 13 if j % i != sign(j / i) * entier(abs(j / i)) 14 then 15 begin 16 outreal(1, j); 17 outreal(1, i); 18 outreal(1, j % i) 19 end; 20 end Compiling... Executing... *** TEST 054 *** Translating... 1 begin 2 3 comment library5; 4 5 integer procedure tsign(x); 6 value 7 x; 8 real 9 x; 10 tsign := 11 if x > 0 then 12 1 13 else if x < 0 then 14 - 1 15 else 16 0; 17 18 integer procedure tentier(x); 19 value 20 x; 21 real 22 x; 23 tentier := x - .5; 24 25 real procedure tabs(x); 26 value 27 x; 28 real 29 x; 30 tabs := 31 if x < 0 then 32 - x 33 else 34 x; 35 36 real 37 x; 38 for x := - 100, 39 - 100.1, 40 - 99.4, 41 - .4, 42 - .1, 43 0, 44 .1, 45 .4, 46 .6, 47 300 do 48 if tsign(x) != sign(x) | tentier(x) != entier(x) | 49 tabs(x) != abs(x) then 50 outreal(1, x) 51 end Compiling... Executing... *** TEST 055 *** Translating... 1 begin 2 3 comment library9; 4 5 6 integer array 7 eq[1 : 9]; 8 integer 9 i; 10 real 11 x, 12 y; 13 procedure print eq; 14 for i := 1 step 1 until 9 do 15 outreal(1, eq[i]); 16 17 procedure test(a, b, c); 18 value 19 a, 20 b, 21 c; 22 real 23 a, 24 b, 25 c; 26 begin 27 procedure inc(a, b, i); 28 value 29 a, 30 b, 31 i; 32 real 33 a, 34 b; 35 integer 36 i; 37 if a < b then 38 eq[i] := eq[i] + 1 39 else if a = b then 40 eq[i + 1] := eq[i + 1] + 1 41 else 42 eq[i + 2] := eq[i + 2] + 1; 43 44 inc(a, b, 1); 45 inc(b, c, 4); 46 inc(c, a, 7) 47 end; 48 49 50 for i := 1 step 1 until 9 do 51 eq[i] := 0; 52 i := 1; 53 for x := 54 0.01, 0.02, 0.03, 0.04, 0.05, 55 0.06, 0.07, 0.08, 0.09, 0.10, 56 0.11, 0.12, 0.13, 0.14, 0.15, 57 0.16, 0.17, 0.18, 0.19, 0.20, 58 0.21, 0.22, 0.23, 0.24, 0.25, 59 0.26, 0.27, 0.28, 0.29, 0.30, 60 0.31, 0.32, 0.33, 0.34, 0.35, 61 0.36, 0.37, 0.38, 0.39, 0.40, 62 0.41, 0.42, 0.43, 0.44, 0.45, 63 0.46, 0.47, 0.48, 0.49, 0.50, 64 0.51, 0.52, 0.53, 0.54, 0.55, 65 0.56, 0.57, 0.58, 0.59, 0.60, 66 0.61, 0.62, 0.63, 0.64, 0.65, 67 0.66, 0.67, 0.68, 0.69, 0.70, 68 0.71, 0.72, 0.73, 0.74, 0.75, 69 0.76, 0.77, 0.78, 0.79, 0.80, 70 0.81, 0.82, 0.83, 0.84, 0.85, 71 0.86, 0.87, 0.88, 0.89, 0.90, 72 0.91, 0.92, 0.93, 0.94, 0.95, 73 0.96, 0.97, 0.98, 0.99, 1.00 74 do 75 begin 76 inreal(0, y); 77 test(x, y, i / 100); 78 i := i + 1 79 end; 80 printeq; 81 i := 1; 82 for x := 83 100.01, 100.02, 100.03, 100.04, 100.05, 84 100.06, 100.07, 100.08, 100.09, 100.10, 85 100.11, 100.12, 100.13, 100.14, 100.15, 86 100.16, 100.17, 100.18, 100.19, 100.20, 87 100.21, 100.22, 100.23, 100.24, 100.25, 88 100.26, 100.27, 100.28, 100.29, 100.30, 89 100.31, 100.32, 100.33, 100.34, 100.35, 90 100.36, 100.37, 100.38, 100.39, 100.40, 91 100.41, 100.42, 100.43, 100.44, 100.45, 92 100.46, 100.47, 100.48, 100.49, 100.50, 93 100.51, 100.52, 100.53, 100.54, 100.55, 94 100.56, 100.57, 100.58, 100.59, 100.60, 95 100.61, 100.62, 100.63, 100.64, 100.65, 96 100.66, 100.67, 100.68, 100.69, 100.70, 97 100.71, 100.72, 100.73, 100.74, 100.75, 98 100.76, 100.77, 100.78, 100.79, 100.80, 99 100.81, 100.82, 100.83, 100.84, 100.85, 100 100.86, 100.87, 100.88, 100.89, 100.90, 101 100.91, 100.92, 100.93, 100.94, 100.95, 102 100.96, 100.97, 100.98, 100.99, 101.00 103 do 104 begin 105 inreal(0, y); 106 test(x, y, 100 + i / 100); 107 i := i + 1 108 end; 109 printeq; 110 i := 1; 111 for x := 112 10000.01,10000.02,10000.03,10000.04,10000.05, 113 10000.06,10000.07,10000.08,10000.09,10000.10, 114 10000.11,10000.12,10000.13,10000.14,10000.15, 115 10000.16,10000.17,10000.18,10000.19,10000.20, 116 10000.21,10000.22,10000.23,10000.24,10000.25, 117 10000.26,10000.27,10000.28,10000.29,10000.30, 118 10000.31,10000.32,10000.33,10000.34,10000.35, 119 10000.36,10000.37,10000.38,10000.39,10000.40, 120 10000.41,10000.42,10000.43,10000.44,10000.45, 121 10000.46,10000.47,10000.48,10000.49,10000.50, 122 10000.51,10000.52,10000.53,10000.54,10000.55, 123 10000.56,10000.57,10000.58,10000.59,10000.60, 124 10000.61,10000.62,10000.63,10000.64,10000.65, 125 10000.66,10000.67,10000.68,10000.69,10000.70, 126 10000.71,10000.72,10000.73,10000.74,10000.75, 127 10000.76,10000.77,10000.78,10000.79,10000.80, 128 10000.81,10000.82,10000.83,10000.84,10000.85, 129 10000.86,10000.87,10000.88,10000.89,10000.90, 130 10000.91,10000.92,10000.93,10000.94,10000.95, 131 10000.96,10000.97,10000.98,10000.99,10001.00 132 do 133 begin 134 inreal(0, y); 135 test(x, y, 10000 + i / 100); 136 i := i + 1 137 end; 138 printeq; 139 i := 2; 140 for x := 141 0.33333333333333333333, 142 0.12500000000000000000, 143 0.06666666666666666667, 144 0.04166666666666666667, 145 0.02857142857142857143, 146 0.02083333333333333333, 147 0.01587301587301587302, 148 0.01250000000000000000, 149 0.01010101010101010101, 150 0.00833333333333333333, 151 0.00699300699300699301, 152 0.00595238095238095238, 153 0.00512820512820512821, 154 0.00446428571428571429, 155 0.00392156862745098039, 156 0.00347222222222222222, 157 0.00309597523219814241, 158 0.00277777777777777778, 159 0.00250626566416040100, 160 0.00227272727272727273, 161 0.00207039337474120083, 162 0.00189393939393939394, 163 0.00173913043478260870, 164 0.00160256410256410256, 165 0.00148148148148148148, 166 0.00137362637362637363, 167 0.00127713920817369093, 168 0.00119047619047619048, 169 0.00111234705228031146, 170 0.00104166666666666667, 171 0.00097751710654936461, 172 0.00091911764705882353, 173 0.00086580086580086580, 174 0.00081699346405228758, 175 0.00077220077220077220, 176 0.00073099415204678363, 177 0.00069300069300069300, 178 0.00065789473684210526, 179 0.00062539086929330832, 180 0.00059523809523809524, 181 0.00056721497447532615, 182 0.00054112554112554113, 183 0.00051679586563307494, 184 0.00049407114624505929, 185 0.00047281323877068558, 186 0.00045289855072463768, 187 0.00043421623968736431, 188 0.00041666666666666667, 189 0.00040016006402561024, 190 0.00038461538461538462, 191 0.00036995930447650758, 192 0.00035612535612535613, 193 0.00034305317324185249, 194 0.00033068783068783069, 195 0.00031897926634768740, 196 0.00030788177339901478, 197 0.00029735355337496283, 198 0.00028735632183908046, 199 0.00027785495971103084, 200 0.00026881720430107527, 201 0.00026021337496747333, 202 0.00025201612903225806, 203 0.00024420024420024420, 204 0.00023674242424242424, 205 0.00022962112514351320, 206 0.00022281639928698752, 207 0.00021630975556997621, 208 0.00021008403361344538, 209 0.00020412329046744234, 210 0.00019841269841269841, 211 0.00019293845263360988, 212 0.00018768768768768769, 213 0.00018264840182648402, 214 0.00017780938833570413, 215 0.00017316017316017316, 216 0.00016869095816464238, 217 0.00016439256945586060, 218 0.00016025641025641026, 219 0.00015627441787779341, 220 0.00015243902439024390, 221 0.00014874312063067083, 222 0.00014518002322880372, 223 0.00014174344436569809, 224 0.00013842746400885936, 225 0.00013522650439486139, 226 0.00013213530655391121, 227 0.00012914890869172155, 228 0.00012626262626262626, 229 0.00012347203358439313, 230 0.00012077294685990338, 231 0.00011816140848398913, 232 0.00011563367252543941, 233 0.00011318619128466327, 234 0.00011081560283687943, 235 0.00010851871947911015, 236 0.00010629251700680272, 237 0.00010413412475268145, 238 0.00010204081632653061, 239 0.00010001000100010001 240 do 241 begin 242 inreal(0, y); 243 test(x, y, 1 / ( i * i - 1 ) ); 244 i := i + 1 245 end; 246 printeq; 247 248 end Compiling... Executing... 0 100 0 0 100 0 0 100 0 0 200 0 0 200 0 0 200 0 0 300 0 0 300 0 0 300 0 0 399 0 2 394 3 3 394 2 *** TEST 056 *** Translating... 1 begin 2 3 comment library5; 4 5 integer 6 i, 7 j, 8 case; 9 real 10 x, 11 y; 12 procedure requal(a, b); 13 value 14 a, 15 b; 16 real 17 a, 18 b; 19 if a != b then 20 begin 21 outreal(1, a); 22 outreal(1, b); 23 outreal(1, case) 24 end 25 else 26 case := case + 1; 27 28 case := 1; 29 x := 2.0; 30 y := 3.0; 31 i := 2; 32 j := 3; 33 requal(x^i, 4.0); 34 if i^j != 8 then 35 begin 36 outreal(1, i^j); 37 outreal(1, 8); 38 end; 39 requal(x^0, 1.0); 40 if i^0 != 1 then 41 begin 42 outreal(1, i^0); 43 outreal(1, 1) 44 end; 45 requal(x^( - i), 1.0 / (2.0 * 2.0)); 46 requal(i^( - i), 1.0 / (2.0 * 2.0)); 47 requal(x^y, exp(y * ln(x))); 48 requal(j^y, exp(y * ln(j))); 49 requal(0.0^x, 0.0); 50 requal(0^x, 0.0); 51 52 comment should fail; 53 54 requal(( - x)^y, - 1) 55 end Compiling... Executing... fault: expi undefined -2 procedure requal, file test056.alg, line 17 main program, file test056.alg, line 46 *** TEST 057 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 real 8 x; 9 i := 0; 10 x := 0.0; 11 outreal(1, x^i) 12 end Compiling... Executing... fault: expn undefined 0 procedure outreal, file alglib1.alg, line 171 main program, file test057.alg, line 11 *** TEST 058 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 i := 0; 8 outreal(1, i^i) 9 end Compiling... Executing... fault: expi undefined 0 procedure outreal, file alglib1.alg, line 171 main program, file test058.alg, line 8 *** TEST 059 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := - 1.0; 8 outreal(1, 0.0^x) 9 end Compiling... Executing... fault: expr undefined 0 procedure outreal, file alglib1.alg, line 171 main program, file test059.alg, line 8 *** TEST 060 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := - 1.0; 8 outreal(1, 0^x) 9 end Compiling... Executing... fault: expr undefined 0 procedure outreal, file alglib1.alg, line 171 main program, file test060.alg, line 8 *** TEST 061 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 real 8 x; 9 x := 3.2; 10 i := - 2; 11 outreal(1, i^x) 12 end Compiling... Executing... fault: expr undefined -2 procedure outreal, file alglib1.alg, line 171 main program, file test061.alg, line 11 *** TEST 062 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i, 7 j; 8 i := 0; 9 j := - 2; 10 outreal(1, i^j) 11 end Compiling... Executing... fault: expi undefined -2 procedure outreal, file alglib1.alg, line 171 main program, file test062.alg, line 10 *** TEST 063 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 real 8 x; 9 x := 0.0; 10 i := - 2; 11 outreal(1, x^i) 12 end Compiling... Executing... inf *** TEST 064 *** Translating... 1 begin 2 3 comment library 1; 4 integer procedure p(b); 5 value 6 b; 7 Boolean 8 b; 9 p := (if b then 1 else 3.3) % 6; 10 11 outreal(1, p(true)); 12 outreal(1, p(false)) 13 end test064.alg:9: operand preceding `%' is not of integer type test064.alg:13: one error detected on the second pass; translation terminated *** TEST 065 *** Translating... 1 begin 2 3 comment library 1; 4 integer 5 i, 6 j; 7 i := 2; 8 j := 3; 9 outreal(1, i^j % j) 10 end Compiling... Executing... 2 *** TEST 066 *** Translating... 1 begin 2 3 comment library 1; 4 integer 5 i, 6 j, 7 k, 8 case; 9 10 procedure equal(i, j); 11 value 12 i, 13 j; 14 integer 15 i, 16 j; 17 if i != j then 18 begin 19 outreal(1, case); 20 outreal(1, i); 21 outreal(1, j) 22 end 23 else 24 case := case + 1; 25 26 i := 2; 27 j := 5; 28 k := 9; 29 case := 0; 30 equal(i + j + k, 16); 31 equal(i + j - k, - 2); 32 equal(i + j * k, 47); 33 equal(i + j % k, 2); 34 equal(i + j^k, 1953127); 35 equal(i - j + k, 6); 36 equal(i - j - k, - 12); 37 equal(i - j * k, - 43); 38 equal(i - j % k, 2); 39 equal(i - j^k, -1953123); 40 equal(i * j + k, 19); 41 equal(i * j - k, 1); 42 equal(i * j * k, 90); 43 equal(i * j % k, 1); 44 equal(i * j^2, 50); 45 equal(j % i + k, 11); 46 equal(j % i - k, - 7); 47 equal(j % i * k, 18); 48 equal(j % i % k, 0); 49 equal(j % i^k, 0); 50 equal(i^j + k, 41); 51 equal(i^j - k, 23); 52 equal(i^j * k, 288); 53 equal(i^j % k, 3); 54 equal(i^j^2, 1024); 55 outreal(1, case) 56 end Compiling... Executing... 25 *** TEST 067 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i, 7 j; 8 i := 3; 9 j := - 2; 10 outreal(1, (81 * i^j) % 2); 11 end Compiling... Executing... fault: expi undefined -2 procedure outreal, file alglib1.alg, line 171 main program, file test067.alg, line 10 *** TEST 068 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 switch s := 8 s1, 9 s2, 10 s3, 11 s4; 12 for i := 1 step 1 until 4 do 13 begin 14 go to s[i]; 15 s1 :; 16 if i != 1 then 17 outreal(1, i) 18 else 19 go to exit; 20 s2 :; 21 if i != 2 then 22 outreal(1, i) 23 else 24 go to exit; 25 s3 :; 26 if i != 3 then 27 outreal(1, i) 28 else 29 go to exit; 30 s4 :; 31 if i != 4 then 32 outreal(1, i) 33 else 34 go to exit; 35 exit :; 36 end; 37 end test068.alg:36: warning: unlabelled dummy statement test068.alg:37: warning: unlabelled dummy statement test068.alg:37: identifier `s1' not declared (see line 8) test068.alg:37: identifier `s2' not declared (see line 9) test068.alg:37: identifier `s3' not declared (see line 10) test068.alg:37: identifier `s4' not declared (see line 11) test068.alg:37: 4 errors detected on the first pass; translation terminated *** TEST 069 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 switch s := 8 s1, 9 s2, 10 s3, 11 s4; 12 for i := 1, 13 2, 14 3 do 15 begin 16 go to s[i]; 17 s1 :; 18 if i != 1 then 19 outreal(1, i) 20 else 21 s2 : if i != 2 then 22 outreal(1, i) 23 end; 24 s3 :; 25 outreal(1, i); 26 go to s[i + 1]; 27 s4 :; 28 outreal(1, i) 29 end test069.alg:29: identifier `s1' not declared (see line 8) test069.alg:29: identifier `s2' not declared (see line 9) test069.alg:29: 2 errors detected on the first pass; translation terminated *** TEST 070 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 switch s := 8 s1, 9 s2, 10 s3; 11 i := 1; 12 go to s[i]; 13 for i := 1, 14 2, 15 3 do 16 begin 17 s1 :; 18 outreal(1, 10); 19 s2 :; 20 outreal(1, 20); 21 outreal(1, i) 22 end; 23 s3 :; 24 outreal(1, 30) 25 end test070.alg:25: identifier `s1' not declared (see line 8) test070.alg:25: identifier `s2' not declared (see line 9) test070.alg:25: 2 errors detected on the first pass; translation terminated *** TEST 071 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i, 7 case; 8 Boolean 9 b; 10 real 11 x; 12 integer procedure p(k, q); 13 value 14 k; 15 integer 16 k; 17 integer procedure 18 q; 19 p := 20 if k = 1 then 21 q(i) 22 else if k = 2 then 23 q(b) 24 else if k = 3 then 25 q(x) 26 else 27 q(q(20)); 28 29 integer procedure q1(i); 30 value 31 i; 32 integer 33 i; 34 q1 := 100 + i; 35 36 integer procedure q2(b); 37 value 38 b; 39 Boolean 40 b; 41 q2 := 200 + (if b then 1 else 0); 42 43 integer procedure q3(x); 44 value 45 x; 46 real 47 x; 48 q3 := 300 + x; 49 50 procedure fail(m, n); 51 value 52 m, 53 n; 54 integer 55 m, 56 n; 57 if m != n then 58 begin 59 outreal(1, m); 60 outreal(1, n); 61 outreal(1, case) 62 end 63 else 64 case := case + 1; 65 66 i := 1; 67 x := 10.4; 68 case := 0; 69 b := false; 70 fail(p(1, q1), 101); 71 fail(p(4, q1), 220); 72 fail(p(2, q2), 200); 73 fail(p(3, q3), 310); 74 fail(p(4, q3), 620); 75 outreal(1, case) 76 end Compiling... Executing... 5 *** TEST 072 *** Translating... 1 begin 2 3 comment library 3; 4 5 integer 6 i, 7 case; 8 Boolean 9 b; 10 real 11 x; 12 integer procedure p(k, q); 13 value 14 k; 15 integer 16 k; 17 integer procedure 18 q; 19 p := 20 if k = 1 then 21 q(i) 22 else if k = 2 then 23 q 24 else if k = 3 then 25 q(x) 26 else 27 q(q(20)); 28 29 integer procedure q1(i); 30 value 31 i; 32 integer 33 i; 34 q1 := 100 + i; 35 36 integer procedure q2; 37 q2 := 200 + (if b then 1 else 0); 38 39 integer procedure q3(x); 40 value 41 x; 42 real 43 x; 44 q3 := 300 + x; 45 46 procedure fail(m, n); 47 value 48 m, 49 n; 50 integer 51 m, 52 n; 53 if m != n then 54 begin 55 outreal(1, m); 56 outreal(1, n); 57 outreal(1, case) 58 end 59 else 60 case := case + 1; 61 62 i := 1; 63 x := 10.4; 64 case := 0; 65 b := false; 66 fail(p(1, q1), 101); 67 fail(p(4, q1), 220); 68 fail(p(2, q2), 200); 69 fail(p(3, q3), 310); 70 fail(p(4, q3), 620); 71 outreal(1, case) 72 end test072.alg:24: number of parameters in function designator or procedure statement conflicts with earlier use of procedure `q' test072.alg:68: number of parameters of procedure `q2' passed as actual parameter not equal to number of parameters of formal procedure `q' as implied in declaration of procedure `p' beginning at line 12 test072.alg:72: 2 errors detected on the second pass; translation terminated *** TEST 073 *** Translating... 1 real procedure cputime; 2 inline("my_dsa.retval.u.real_val = (double)clock() / (double)CLOCKS_PER_SEC;"); 3 4 begin 5 6 comment library 1; 7 8 9 integer 10 i, 11 j, 12 k, 13 k1; 14 real 15 t1, 16 t2; 17 integer procedure ackermann(m, n); 18 value 19 m, 20 n; 21 integer 22 m, 23 n; 24 ackermann := 25 if m = 0 then 26 n + 1 27 else if n = 0 then 28 ackermann(m - 1, 1) 29 else 30 ackermann(m - 1, ackermann(m, n - 1)); 31 32 k := 16; 33 k1 := 1; 34 for i := 1 step 1 until 6 do 35 begin 36 t1 := cputime; 37 j := ackermann(3, i); 38 t2 := cputime; 39 if j != k - 3 then 40 begin 41 outreal(1, i); 42 outreal(1, j) 43 end; 44 outreal(1, t2 - t1); 45 outreal(1, 3 * (t2 - t1) / (512 * k1 - 15 * k + 9 * i + 37) ); 46 k1 := 4 * k1; 47 k := 2 * k; 48 end 49 end Compiling... Executing... 0 0 0 0 0.0010000000002 4.1118421061e-07 0.00300000000061 2.91064325275e-07 0.0110000000022 2.59201658943e-07 0.0539999999964 3.13528766244e-07 *** TEST 074 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 n; 7 n := 3; 8 begin 9 array 10 a[1 : if n = 3 then 3 else - 100]; 11 integer 12 n; 13 n := 2; 14 outreal(1, n); 15 end; 16 outreal(1, n) 17 end test074.alg:15: warning: unlabelled dummy statement test074.alg:10: identifier `n' in bound expression declared in same program block as array test074.alg:17: one error detected on the second pass; translation terminated *** TEST 075 *** Translating... 1 begin 2 3 comment library 9; 4 5 6 integer array 7 eq[1 : 3]; 8 integer 9 i; 10 real 11 x, 12 y; 13 procedure inc(a, b); 14 value 15 a, 16 b; 17 real 18 a, 19 b; 20 if a < b then 21 eq[1] := eq[1] + 1 22 else if a = b then 23 eq[2] := eq[2] + 1 24 else 25 eq[3] := eq[3] + 1; 26 27 28 29 for i := 1 step 1 until 3 do 30 eq[i] := 0; 31 for i := 2 step 1 until 100 do 32 begin 33 inreal(2, x); 34 y := 1 / (i * i - 1); 35 outreal(1, y); 36 inc(x, y) 37 end; 38 for i := 1 step 1 until 3 do 39 outreal(1, eq[i]); 40 41 42 end Compiling... Executing... fault: unable to connect channel 2 to file `FILE_2' for input - No such file or directory procedure inreal, file alglib1.alg, line 165 main program, file test075.alg, line 33 *** TEST 076 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x, 7 y; 8 integer 9 i, 10 j; 11 array 12 a[1 : 10]; 13 x := y := 1.0; 14 i := j := 0; 15 begin 16 procedure p; 17 begin 18 x := 20; 19 i := x + y; 20 q(a[3], i + j) 21 end; 22 23 procedure q(l, k); 24 value 25 k; 26 label 27 l; 28 integer 29 k; 30 if k = 0 then 31 go to l; 32 33 switch a := 34 a1, 35 a2, 36 a3; 37 integer procedure j; 38 j := y; 39 40 real 41 i; 42 real procedure y; 43 y := x; 44 45 integer 46 x; 47 a1 :; 48 x := 10; 49 q(a[2], y - x); 50 a2 :; 51 p; 52 if i = 0 | j = 0 | x = 1.0 | y = 1.0 then 53 outreal(1, 100); 54 a3 :; 55 end; 56 if i = 0 & j = 0 & x = 1.0 & y = 1.0 then 57 outreal(1, 0) 58 end Compiling... Executing... 0 *** TEST 077 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 sum; 7 procedure p1(s, r, i, b, ra, ia); 8 string 9 s; 10 real 11 r; 12 integer 13 i; 14 Boolean 15 b; 16 real array 17 ra; 18 integer array 19 ia; 20 sum := sum + r + i + (if b then 1 else 0) + ra[1] + 21 ia[1]; 22 23 procedure p2(ba, l, sw, pr, rpr, ipr, bpr); 24 Boolean array 25 ba; 26 label 27 l; 28 switch 29 sw; 30 procedure 31 pr; 32 real procedure 33 rpr; 34 integer procedure 35 ipr; 36 Boolean procedure 37 bpr; 38 begin 39 pr; 40 sum := sum + rpr + ipr; 41 if bpr then 42 go to l; 43 if ba[1] then 44 go to sw[2] 45 end; 46 47 procedure p3(r, i, b, ra, ia, ba, l); 48 value 49 r, 50 i, 51 b, 52 ra, 53 ia, 54 ba, 55 l; 56 real 57 r; 58 integer 59 i; 60 Boolean 61 b; 62 real array 63 ra; 64 integer array 65 ia; 66 Boolean array 67 ba; 68 label 69 l; 70 begin 71 sum := sum + r + i + ra[1] + ia[1] + (if b then 1 72 else 0) + (if ba[1] then 1 else 0); 73 if ba[1] then 74 go to l 75 end; 76 77 real 78 r; 79 Boolean 80 b; 81 real array 82 ra[1 : 1]; 83 integer array 84 ia[1 : 1]; 85 Boolean array 86 ba[1 : 1]; 87 integer procedure ipr; 88 ipr := 2 * sum; 89 90 real procedure rpr; 91 rpr := 3 * sum; 92 93 Boolean procedure bpr; 94 bpr := ! b; 95 96 procedure pr; 97 sum := 5 * sum + 1; 98 99 switch ss := 100 work, 101 fail; 102 sum := 0; 103 ia[1] := - 2; 104 ra[1] := 3.55; 105 ba[1] := false; 106 b := true; 107 r := 6.4; 108 p1( "ab", r, sum, b, ra, ia); 109 if sum != 9 then 110 outreal(1, sum); 111 p2(ba, ss[2], ss, pr, rpr, ipr, bpr); 112 if sum != 276 then 113 outreal(1, sum); 114 work :; 115 outreal(1, 0); 116 p3(4.6, - 200, true, ra, ia, ba, if true then ss[2] else 117 fail); 118 if sum != 83 then 119 outreal(1, sum); 120 p1( "cd", rpr, ipr, bpr, ra, ia); 121 if sum != 500 then 122 outreal(1, sum); 123 p3(rpr, ipr, bpr, ra, ia, ba, fail); 124 if sum != 3002 then 125 outreal(1, sum); 126 if false then 127 fail : outreal(1, - 1); 128 end Compiling... Executing... 0 *** TEST 078 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 sum; 7 procedure p1(s, r, i, b, ra, ia); 8 string 9 s; 10 real 11 r; 12 integer 13 i; 14 Boolean 15 b; 16 real array 17 ra; 18 integer array 19 ia; 20 sum := sum + r + i + (if b then 1 else 0) + ra[1] + 21 ia[1]; 22 23 procedure p2(ba, l, sw, pr, rpr, ipr, bpr); 24 Boolean array 25 ba; 26 label 27 l; 28 switch 29 sw; 30 procedure 31 pr; 32 real procedure 33 rpr; 34 integer procedure 35 ipr; 36 Boolean procedure 37 bpr; 38 begin 39 pr; 40 sum := sum + rpr + ipr; 41 if bpr then 42 go to l; 43 if ba[1] then 44 go to sw[2] 45 end; 46 47 procedure p3(r, i, b, ra, ia, ba, l); 48 value 49 r, 50 i, 51 b, 52 ra, 53 ia, 54 ba, 55 l; 56 real 57 r; 58 integer 59 i; 60 Boolean 61 b; 62 real array 63 ra; 64 integer array 65 ia; 66 Boolean array 67 ba; 68 label 69 l; 70 begin 71 sum := sum + r + i + ra[1] + ia[1] + (if b then 1 72 else 0) + (if ba[1] then 1 else 0); 73 if ba[1] then 74 go to l 75 end; 76 77 real 78 r; 79 Boolean 80 b; 81 real array 82 ra[1 : 1]; 83 integer array 84 ia[1 : 1]; 85 Boolean array 86 ba[1 : 1]; 87 integer procedure ipr; 88 ipr := 2 * sum; 89 90 real procedure rpr; 91 rpr := 3 * sum; 92 93 Boolean procedure bpr; 94 bpr := ! b; 95 96 procedure pr; 97 sum := 5 * sum + 1; 98 99 switch ss := 100 work, 101 fail; 102 sum := 0; 103 ia[1] := - 2; 104 ra[1] := 3.55; 105 ba[1] := false; 106 b := true; 107 r := 6.4; 108 p1(ra, "ab", "ab", "ab", "ab", "ab" ); 109 p1(ss, ra, ra, ra, ss, ss); 110 p1(pr, ss, ss, ss, pr, pr); 111 p1(ss[2], pr, pr, pr, ss[2], ss[2]); 112 p1(true, ss[2], ss[2], ss[2], true, true); 113 p1(r, false, false, r, r, r); 114 p2( "ab", "ab", "ab", "ab", "ab", "ab", "ab" ); 115 p2(ra, ra, ra, ra, ra, ra, ra); 116 p2(ss, ss, ss[2], ss, ss, ss, ss); 117 p2(pr, pr, pr, r, pr, pr, pr); 118 p2(fail, ss, fail, fail, fail, fail, fail); 119 p2(true, true, true, true, true, true, true); 120 p2(r, r, r, r, r, r, r); 121 p3( "ab", "ab", "ab", "ab", "ab", "ab", "ab" ); 122 p3(ra, ra, ra, r, r, r, ra); 123 p3(ss, ss, ss, ss, ss, ss, ss); 124 p3(pr, pr, pr, pr, pr, pr, pr); 125 p3(fail, fail, fail, fail, fail, fail, ss); 126 p3(true, true, r, true, true, true, true); 127 p3(true, true, r, r, r, r, r); 128 work :; 129 if false then 130 fail : outreal(1, - 1); 131 end test078.alg:131: warning: unlabelled dummy statement test078.alg:108: array `ra' passed as actual parameter conflicts with kind of formal parameter `s' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:108: string passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:108: string passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:108: string passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:108: string passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:108: string passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:109: switch `ss' passed as actual parameter conflicts with kind of formal parameter `s' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:109: array `ra' passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:109: array `ra' passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:109: array `ra' passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:109: switch `ss' passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:109: switch `ss' passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:110: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `s' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:110: switch `ss' passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:110: switch `ss' passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:110: switch `ss' passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:110: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:110: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:111: expression passed as actual parameter conflicts with kind of formal parameter `s' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:111: procedure identifier `pr' that is not in itself a complete expression and passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:111: procedure identifier `pr' that is not in itself a complete expression and passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:111: procedure identifier `pr' that is not in itself a complete expression and passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:111: expression passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:111: expression passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:112: expression passed as actual parameter conflicts with kind of formal parameter `s' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:112: type of expression passed as actual parameter conflicts with type of formal parameter `r' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:112: type of expression passed as actual parameter conflicts with type of formal parameter `i' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:112: type of expression passed as actual parameter conflicts with type of formal parameter `b' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:113: expression passed as actual parameter conflicts with kind of formal parameter `s' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:113: type of expression passed as actual parameter conflicts with type of formal parameter `r' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:113: type of expression passed as actual parameter conflicts with type of formal parameter `b' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:113: expression passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:113: expression passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p1' beginning at line 7 test078.alg:114: string passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:114: string passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:114: string passed as actual parameter conflicts with kind of formal parameter `sw' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:114: string passed as actual parameter conflicts with kind of formal parameter `pr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:114: string passed as actual parameter conflicts with kind of formal parameter `rpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:114: string passed as actual parameter conflicts with kind of formal parameter `ipr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:114: string passed as actual parameter conflicts with kind of formal parameter `bpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:115: type of array `ra' passed as actual parameter conflicts with type of formal array `ba' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:115: array `ra' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:115: array `ra' passed as actual parameter conflicts with kind of formal parameter `sw' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:115: array `ra' passed as actual parameter conflicts with kind of formal parameter `pr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:115: array `ra' passed as actual parameter conflicts with kind of formal parameter `rpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:115: array `ra' passed as actual parameter conflicts with kind of formal parameter `ipr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:115: array `ra' passed as actual parameter conflicts with kind of formal parameter `bpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:116: switch `ss' passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:116: switch `ss' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:116: expression passed as actual parameter conflicts with kind of formal parameter `sw' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:116: switch `ss' passed as actual parameter conflicts with kind of formal parameter `pr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:116: switch `ss' passed as actual parameter conflicts with kind of formal parameter `rpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:116: switch `ss' passed as actual parameter conflicts with kind of formal parameter `ipr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:116: switch `ss' passed as actual parameter conflicts with kind of formal parameter `bpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:117: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:117: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:117: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `sw' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:117: expression passed as actual parameter conflicts with kind of formal parameter `pr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:117: type of procedure `pr' passed as actual parameter conflicts with type of formal procedure `rpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:117: type of procedure `pr' passed as actual parameter conflicts with type of formal procedure `ipr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:117: type of procedure `pr' passed as actual parameter conflicts with type of formal procedure `bpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:118: expression passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:118: switch `ss' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:118: expression passed as actual parameter conflicts with kind of formal parameter `sw' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:118: expression passed as actual parameter conflicts with kind of formal parameter `pr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:118: expression passed as actual parameter conflicts with kind of formal parameter `rpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:118: expression passed as actual parameter conflicts with kind of formal parameter `ipr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:118: expression passed as actual parameter conflicts with kind of formal parameter `bpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:120: expression passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:120: type of expression passed as actual parameter conflicts with type of formal parameter `l' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:120: expression passed as actual parameter conflicts with kind of formal parameter `sw' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:120: expression passed as actual parameter conflicts with kind of formal parameter `pr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:120: expression passed as actual parameter conflicts with kind of formal parameter `rpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:120: expression passed as actual parameter conflicts with kind of formal parameter `ipr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:120: expression passed as actual parameter conflicts with kind of formal parameter `bpr' as specified in declaration of procedure `p2' beginning at line 23 test078.alg:121: string passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:121: string passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:121: string passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:121: string passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:121: string passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:121: string passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:121: string passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:122: array `ra' passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:122: array `ra' passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:122: array `ra' passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:122: expression passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:122: expression passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:122: expression passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:122: array `ra' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:123: switch `ss' passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:123: switch `ss' passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:123: switch `ss' passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:123: switch `ss' passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:123: switch `ss' passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:123: switch `ss' passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:123: switch `ss' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:124: procedure identifier `pr' that is not in itself a complete expression and passed as actual parameter conflicts with kind of formal parameter `r' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:124: procedure identifier `pr' that is not in itself a complete expression and passed as actual parameter conflicts with kind of formal parameter `i' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:124: procedure identifier `pr' that is not in itself a complete expression and passed as actual parameter conflicts with kind of formal parameter `b' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:124: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:124: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:124: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:124: procedure `pr' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:125: type of expression passed as actual parameter conflicts with type of formal parameter `r' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:125: type of expression passed as actual parameter conflicts with type of formal parameter `i' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:125: type of expression passed as actual parameter conflicts with type of formal parameter `b' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:125: expression passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:125: expression passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:125: expression passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:125: switch `ss' passed as actual parameter conflicts with kind of formal parameter `l' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:126: type of expression passed as actual parameter conflicts with type of formal parameter `b' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:127: type of expression passed as actual parameter conflicts with type of formal parameter `b' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:127: expression passed as actual parameter conflicts with kind of formal parameter `ra' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:127: expression passed as actual parameter conflicts with kind of formal parameter `ia' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:127: expression passed as actual parameter conflicts with kind of formal parameter `ba' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:127: type of expression passed as actual parameter conflicts with type of formal parameter `l' as specified in declaration of procedure `p3' beginning at line 47 test078.alg:131: 116 errors detected on the second pass; translation terminated *** TEST 079 *** Translating... 1 begin 2 integer 3 i; 4 real 5 r; 6 Boolean 7 b; 8 array 9 a1[1 : i + b], 10 a2[2 : 4, 5 : 7]; 11 switch s := 12 if r * p0 < 0 then l else l2; 13 procedure p0; 14 r := i % r; 15 16 procedure p1(f); 17 real 18 f; 19 b := i + r; 20 21 l :; 22 b := i > s; 23 b := b | p0; 24 r := b + a1; 25 l2 :; 26 r := b & b; 27 i := p1(r); 28 go to b; 29 i; 30 p1(a2 / r); 31 r[i] := 5; 32 i := 33 if b then 34 s 35 else 36 r; 37 p1(if b then b else i - i); 38 r := b := b & b; 39 for i := b step 1 until r do 40 a1[s] := a2[2]; 41 a1 := 0; 42 if r then 43 go to l; 44 for p0 := 1, 45 2 do 46 a2[b, i] := 0; 47 begin 48 array 49 q[b : 1]; 50 51 end; 52 p1(i, r); 53 p1; 54 end test079.alg:51: warning: unlabelled dummy statement test079.alg:54: warning: unlabelled dummy statement test079.alg:9: identifier `i' in bound expression declared in same program block as array test079.alg:9: identifier `b' in bound expression declared in same program block as array test079.alg:9: operand following `+' or `-' is not of arithmetic type test079.alg:12: invalid use of typeless procedure `p0' in function designator test079.alg:12: operand following `*', `/', or `%' is not of arithmetic type test079.alg:16: operand following `%' is not of integer type test079.alg:21: type of identifier `b' in left part of assignment statement incompatible with type of assigned expression test079.alg:23: invalid use of identifier `s' as expression operand test079.alg:24: invalid use of typeless procedure `p0' in function designator test079.alg:24: operand following `|' is not of Boolean type test079.alg:24: operand preceding `+' or `-' is not of arithmetic type test079.alg:25: invalid use of identifier `a1' as expression operand test079.alg:27: type of identifier `r' in left part of assignment statement incompatible with type of assigned expression test079.alg:27: invalid use of typeless procedure `p1' in function designator test079.alg:28: invalid type of assigned expression in assignment statement test079.alg:29: invalid use identifier `b' as a label in go to statement test079.alg:29: expression following `go to' is not of label type test079.alg:30: invalid use of `i' as procedure identifier test079.alg:30: invalid use of identifier `a2' as expression operand test079.alg:31: invalid use of `r' as array identifier test079.alg:36: invalid use of identifier `s' as expression operand test079.alg:37: expressions before and after 'else' incompatible test079.alg:37: type of expression passed as actual parameter conflicts with type of formal parameter `f' as specified in declaration of procedure `p1' beginning at line 16 test079.alg:39: type of identifier `r' in left part of assignment statement incompatible with type of assigned expression test079.alg:39: invalid type of expression assigned to controlled variable test079.alg:40: invalid use of identifier `s' as expression operand test079.alg:40: number of subscripts in subscripted variable conflicts with declaration of array `a2' at line 10 test079.alg:41: invalid use of array identifier `a1' in left part of assignment statement test079.alg:43: expression following `if' is not of Boolean type test079.alg:44: invalid use of identifier `p0' as controlled variable test079.alg:46: invalid type of subscript expression test079.alg:49: bound expression is not of arithmetic type test079.alg:53: number of parameters in function designator or procedure statement conflicts with declaration of procedure `p1' beginning at line 16 test079.alg:54: number of parameters in function designator or procedure statement conflicts with declaration of procedure `p1' beginning at line 16 test079.alg:54: 34 errors detected on the second pass; translation terminated *** TEST 080 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 integer array 8 a[1 : 10]; 9 i := 1; 10 for a[i] := 1, 11 2, 12 3, 13 4, 14 5, 15 6, 16 7, 17 8, 18 9, 19 10 do 20 i := i + 1; 21 for i := 1 step 1 until 10 do 22 if a[i] != i then 23 outreal(1, i); 24 outreal(1, 0) 25 end test080.alg:10: subscripted controlled variable not allowed test080.alg:10: missing ':=' after controlled variable identifier test080.alg:10: invalid use of delimiter `[' as expression operand test080.alg:10: missing `do' delimiter after for list test080.alg:10: invalid use of identifier `i' test080.alg:25: 5 errors detected on the first pass; translation terminated *** TEST 081 *** Translating... 1 begin 2 3 comment library 1; 4 5 array 6 v, 7 a, 8 c[1 : 1]; 9 integer 10 k; 11 integer procedure i; 12 begin 13 i := 1; 14 k := k + 1 15 end; 16 17 k := 0; 18 a[i] := 1; 19 c[i] := 3; 20 for v[i] := a[i] step a[i] until c[i] do 21 ; 22 outreal(1, k) 23 end test081.alg:20: subscripted controlled variable not allowed test081.alg:20: missing ':=' after controlled variable identifier test081.alg:20: invalid use of delimiter `[' as expression operand test081.alg:20: missing `do' delimiter after for list test081.alg:20: invalid use of identifier `i' test081.alg:23: 5 errors detected on the first pass; translation terminated *** TEST 082 *** Translating... 1 begin 2 3 comment library5; 4 5 integer procedure none; 6 none := 1; 7 8 none; 9 sin(1.0); 10 abs(3); 11 ln(.2); 12 exp(4); 13 entier(none); 14 sign(sqrt(8)); 15 outreal(1, none) 16 end Compiling... Executing... 1 *** TEST 083 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 nn; 7 switch a := 8 b[1], 9 b[2]; 10 switch b := 11 a[g], 12 a[2]; 13 integer procedure f(n, s); 14 value 15 n; 16 integer 17 n; 18 switch 19 s; 20 begin 21 nn := n; 22 go to s[1]; 23 f := nn 24 end; 25 26 integer procedure g; 27 begin 28 integer 29 n; 30 n := nn; 31 g := 0; 32 nn := 33 if n <= 1 then 34 n 35 else 36 f(n - 1, a) + f(n - 2, a) 37 end; 38 39 outreal(1, f(20, a)) 40 end Compiling... Executing... fault: switch designator undefined procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure g, file test083.alg, line 36 procedure f, file test083.alg, line 22 procedure outreal, file alglib1.alg, line 171 main program, file test083.alg, line 7 *** TEST 084 *** Translating... 1 real procedure cputime; 2 inline("my_dsa.retval.u.real_val = (double)clock() / (double)CLOCKS_PER_SEC;"); 3 4 begin 5 comment library 3; 6 7 8 integer i,cl,n,rep; 9 10 array r,a,b[1:30],c[1:10]; 11 12 real j,root,x; 13 14 integer procedure even(x); 15 value x; 16 integer x; 17 even:=if x%2*2 = x then 1 else -1; 18 19 20 procedure gamm(r,a,b,c); 21 array r,a,b,c; 22 begin integer rep,i,cl; 23 real j,root,x; 24 rep:=100*n; 25 outreal(1, cputime); 26 for cl:= 1 step 1 until rep do 27 ; 28 outreal(1, cputime); 29 rep:=n; 30 outreal(1, cputime); 31 for cl:=1 step 1 until rep do 32 for i:= 1 step 1 until 30 do 33 r[i]:=a[i]+b[i]; 34 outreal(1, cputime); 35 for cl:=1 step 1 until rep do 36 for i:=1 step 1 until 30 do 37 r[i]:=a[i]*b[i]; 38 outreal(1, cputime); 39 rep:=6*n; 40 x := .5; 41 outreal(1, cputime); 42 for cl:= 1 step 1 until rep do 43 begin j:=0.0; 44 for i:= 1 step 1 until 10 do 45 j:=(j+c[i])*x 46 end; 47 outreal(1, cputime); 48 outreal(1, j); 49 outreal(1, cputime); 50 for cl:= 1 step 1 until rep do 51 begin j:=c[1]; 52 for i:=2 step 1 until 10 do 53 if c[i]>j then j:=c[i] 54 end; 55 outreal(1, cputime); 56 j:=2; 57 rep := 8*n; 58 outreal(1, cputime); 59 for cl:=1 step 1 until rep do 60 begin root:=1.0; 61 for i:=1 step 1 until 5 do 62 root:= 0.5*(root+j/root) 63 end; 64 outreal(1, cputime); 65 outreal(1, root); 66 end of gamm; 67 68 69 i:=1; 70 for j:=104.5,3.7,-68.9,228.2,-1004.4,500.0,308.1,45.0,152.35,161.8 do 71 begin c[i]:=j; 72 i:=i+1 73 end; 74 for i:=1 step 1 until 30 do 75 begin a[i]:=even(i)*i*i; 76 b[i]:=1-even(i)*i*i 77 end; 78 n := 2000; 79 rep:=100*n; 80 outreal(1, cputime); 81 for cl:= 1 step 1 until rep do 82 ; 83 outreal(1, cputime); 84 rep:=n; 85 outreal(1, cputime); 86 for cl:=1 step 1 until rep do 87 for i:= 1 step 1 until 30 do 88 r[i]:=a[i]+b[i]; 89 outreal(1, cputime); 90 for cl:=1 step 1 until rep do 91 for i:=1 step 1 until 30 do 92 r[i]:=a[i]*b[i]; 93 outreal(1, cputime); 94 rep:=6*n; 95 x := .5; 96 outreal(1, cputime); 97 for cl:= 1 step 1 until rep do 98 begin j:=0.0; 99 for i:= 1 step 1 until 10 do 100 j:=(j+c[i])*x 101 end; 102 outreal(1, cputime); 103 outreal(1, j); 104 outreal(1, cputime); 105 for cl:= 1 step 1 until rep do 106 begin j:=c[1]; 107 for i:=2 step 1 until 10 do 108 if c[i]>j then j:=c[i] 109 end; 110 outreal(1, cputime); 111 j:=2; 112 rep := 8*n; 113 outreal(1, cputime); 114 for cl:=1 step 1 until rep do 115 begin root:=1.0; 116 for i:=1 step 1 until 5 do 117 root:= 0.5*(root+j/root) 118 end; 119 outreal(1, cputime); 120 outreal(1, root); 121 gamm(r,a,b,c); 122 123 end Compiling... Executing... 30256.812 30256.82 30256.82 30256.833 30256.846 30256.846 30256.86 145.422949219 30256.86 30256.875 30256.875 30256.882 1.41421356237 30256.882 30256.89 30256.89 30256.903 30256.916 30256.916 30256.929 145.422949219 30256.929 30256.945 30256.945 30256.952 1.41421356237 *** TEST 085 *** Translating... 1 begin 2 comment library 1; 3 real 4 x, 5 y; 6 procedure dum; 7 ; 8 9 real procedure a; 10 a := x + (if b then 1 else 0); 11 12 Boolean 13 b; 14 s2 :; 15 b := ((true)); 16 g :; 17 begin 18 integer 19 i; 20 x := - 3; 21 if ! b then 22 go to s2; 23 i := 1; 24 y := a - i * x^2; 25 dum 26 end; 27 outreal(1, y / 2) 28 end Compiling... Executing... -5.5 *** TEST 086 *** Translating... 1 prog : 2 3 begin 4 comment library 1; 5 procedure q; 6 begin 7 array 8 a, 9 d[1 : 1, 1 : n], 10 e[0 : 0]; 11 procedure p(x, l); 12 label 13 l; 14 integer procedure 15 x; 16 b : for i := 1 step 1 until n, 17 i + 1 do 18 c : go to 19 if x(a[1, 1] + i, 0) = 0 then 20 l 21 else 22 r; 23 24 m :; 25 a[1, 1] := n; 26 p(in, prog) 27 end q; 28 29 integer procedure in(f, g); 30 value 31 f; 32 real 33 f, 34 g; 35 n := in := 1; 36 37 integer 38 n, 39 i; 40 n := 2; 41 outreal(1, 1); 42 q; 43 outreal(1, 2); 44 r :; 45 outreal(1, 3); 46 end Compiling... Executing... 1 3 *** TEST 087 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 real 8 x; 9 i := 1; 10 for x := .1 step x until 1.0#6 do 11 i := i + 1; 12 outreal(1, i) 13 end Compiling... Executing... 10000001 *** TEST 088 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 a; 7 integer procedure f(x, y); 8 value 9 x, 10 y; 11 integer 12 x, 13 y; 14 a := f := x + 1; 15 16 integer procedure g(x); 17 integer 18 x; 19 x := g := a + 2; 20 21 a := 0; 22 outreal(1, a + f(a, g(a)) / g(a)) 23 end Compiling... Executing... 0.333333333333 *** TEST 089 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 i, 7 j; 8 array 9 a[1 : 2, 1 : 3]; 10 real procedure gps(i, n, z, v); 11 real 12 i, 13 n, 14 z, 15 v; 16 begin 17 for i := 1 step 1 until n do 18 z := v; 19 gps := 1 20 end; 21 22 outreal(1, gps(j, 3.0, i, gps(i, 2.0, a[i, j], i + j))); 23 for i := 1 step 1 until 2 do 24 for j := 1 step 1 until 3 do 25 if a[i, j] != i + j then 26 outreal(1, 11 * i + j) 27 end Compiling... Executing... 1 *** TEST 090 *** Translating... 1 begin 2 comment library5; 3 real 4 r; 5 Boolean 6 b; 7 integer procedure f(x); 8 real 9 x; 10 f := 0; 11 12 integer 13 i, 14 n, 15 s; 16 integer procedure g(y); 17 Boolean 18 y; 19 g := 20 if y then 21 2 22 else 23 3; 24 25 r := 3.5; 26 n := 4; 27 s := r + (1) + n; 28 outreal(1, s); 29 begin 30 real array 31 ra[f(if true then 0 else 0) : 1]; 32 array 33 a[ - 1 : f(0)]; 34 real procedure q; 35 q := r^2; 36 37 s := 38 if + 0 = 0 then 39 sqrt(q) 40 else 41 1 42 end; 43 outreal(1, s); 44 begin 45 procedure w(t, u); 46 string 47 t, 48 u; 49 ; 50 51 w( " a real ", " b end " ); 52 for i := 0 do 53 54 end; 55 if 2 = 2 then 56 begin 57 i := 1 58 end 59 else 60 i := 0; 61 for i := 5 while r < n do 62 c : begin 63 b := true; 64 n := 65 if b | ! b then 66 g(b | b) % s 67 else 68 10; 69 b := 70 if b then 71 false | false 72 else 73 true; 74 r := n / 2 75 end; 76 outreal(1, n); 77 end Compiling... Executing... 9 4 0 *** TEST 091 *** Translating... 1 begin 2 3 comment et comment; 4 5 6 comment library 1; 7 8 real 9 c; 10 array 11 d[ - 0 : + 1, 0#0 : 1.0]; 12 integer procedure r(c); 13 real 14 c; 15 r := 16 if true then 17 c 18 else 19 r(0); 20 21 d[0, 0] := c := c := 1; 22 begin 23 real procedure p; 24 begin 25 q(a, b, c, a[1])encore : (b[1], (1)); 26 for c := 1 step 1 until if false then p 27 else 1 do 28 for c := 1, 29 2 do 30 ; 31 p := (0) 32 end :p; 33 34 switch b := 35 (b[2]), 36 l, 37 if if a[1] = 0 & ! false then true 38 else false then b[a[1] + 1] else l; 39 integer array 40 h, 41 a[1 : c + d[0, 1 - (r( + 1))]], 42 j[0 : 1]; 43 procedure q(a, b, c, d)e : (e, f); 44 integer 45 f; 46 switch 47 b; 48 integer array 49 a; 50 real 51 c; 52 real 53 d; 54 label 55 e; 56 ; 57 58 59 comment begin comment end; 60 61 a[1] := 0; 62 l :; 63 outreal(1, p); 64 c := c + 1 * 1^1; 65 if c = 2 then 66 go to b[p + 3] 67 end 68 end Compiling... Executing... 0 *** TEST 092 *** Translating... 1 begin 2 comment library 1; 3 integer 4 n; 5 integer procedure p(q, r); 6 integer procedure 7 r, 8 q; 9 10 comment (r):integer procedure r; 11 12 begin 13 integer 14 b; 15 b := 3 * q(r); 16 p := b 17 end; 18 19 integer procedure a(f); 20 integer procedure 21 f; 22 a := 2 * f; 23 24 integer procedure b; 25 begin 26 n := n - 1; 27 b := 28 if n = 0 then 29 1 30 else 31 p(a, b) + 1 32 end; 33 34 n := 2; 35 n := p(a, b); 36 outreal(1, n) 37 end Compiling... Executing... 42 *** TEST 093 *** Translating... 1 real procedure cputime; 2 inline("my_dsa.retval.u.real_val = (double)clock() / (double)CLOCKS_PER_SEC;"); 3 4 begin 5 6 comment library 3; 7 8 9 real procedure a(k, x1, x2, x3, x4, x5); 10 value 11 k; 12 integer 13 k; 14 real 15 x1, 16 x2, 17 x3, 18 x4, 19 x5; 20 begin 21 real procedure b; 22 begin 23 k := k - 1; 24 b := a := a(k, b, x1, x2, x3, x4) 25 end; 26 27 if k <= 0 then 28 a := x4 + x5 29 else if b < 0 then 30 31 end; 32 33 outreal(1, cputime); 34 outreal(1, a(10, 1, - 1, - 1, 1, 0)); 35 outreal(1, cputime); 36 end Compiling... Executing... 30268.581 -67 30268.583 *** TEST 094 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 j, 7 k, 8 s; 9 integer procedure f(n); 10 value 11 n; 12 integer 13 n; 14 begin 15 integer 16 i, 17 l; 18 for i := n, 19 s % 2 while s < 16 | s = 28 do 20 begin 21 s := s + i + n; 22 l := i 23 end; 24 f := n + l; 25 end f; 26 27 s := - 1; 28 for j := f(2), 29 f(3) while s = 97 do 30 begin 31 s := s + f(5) + j + s; 32 k := j 33 end; 34 s := s + k; 35 outreal(1, s) 36 end Compiling... Executing... 133 *** TEST 095 *** Translating... 1 begin 2 3 comment library 1; 4 5 real procedure g(x); 6 real 7 x; 8 g := x + 1; 9 10 real procedure a(h); 11 real procedure 12 h; 13 14 comment (h1): real h1; 15 16 begin 17 real procedure loc(x); 18 real 19 x; 20 loc := h(g(x)); 21 22 a := loc(0); 23 end a; 24 25 real procedure b(f, h); 26 real procedure 27 f; 28 29 comment (f1): real f1; 30 31 real procedure 32 h; 33 34 comment (h1): real procedure h1; 35 36 b := f(h(f) + a(g) + g(1)); 37 38 outreal(1, b(g, a)) 39 end Compiling... Executing... 7 *** TEST 096 *** Translating... 1 begin 2 3 comment library 1; 4 5 procedure p(f); 6 real procedure 7 f; 8 9 comment (f1):label f1; 10 11 f((m)); 12 13 b1 :; 14 begin 15 real procedure q(l); 16 label 17 l; 18 begin 19 go to l; 20 q := 0; 21 outreal(1, 1) 22 end; 23 24 b2 :; 25 begin 26 real 27 i; 28 go to n; 29 i := 2; 30 outreal(1, i) 31 end; 32 n :; 33 p(q); 34 outreal(1, 3); 35 end b1; 36 outreal(1, 4); 37 m :; 38 outreal(1, 5) 39 end Compiling... Executing... 5 *** TEST 097 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 x, 7 n, 8 k; 9 real procedure sigma(i, k, l, t); 10 value 11 l; 12 integer 13 i, 14 k, 15 l; 16 real 17 t; 18 begin 19 real 20 x; 21 x := 0; 22 for i := k step 1 until l do 23 x := t + x; 24 sigma := x 25 end sigma; 26 27 x := sigma(n, 1, 4, sigma(k, 1, n, 2) - 1); 28 29 comment working in august 1960 at amsterdam; 30 31 outreal(1, x) 32 end Compiling... Executing... 16 *** TEST 098 *** Translating... 1 begin 2 3 comment library 1; 4 5 real procedure r(a); 6 real 7 a; 8 begin 9 integer procedure p(b, c); 10 integer 11 b, 12 c; 13 p := b + c; 14 15 r := p(a + 1, a) 16 end r; 17 18 real 19 x; 20 begin 21 real 22 y; 23 y := 4; 24 x := r(r(y + 1)) 25 end; 26 outreal(1, x) 27 end Compiling... Executing... 23 *** TEST 099 *** Translating... 1 begin 2 3 comment library 1; 4 5 procedure p(a, b, c, d); 6 value 7 b, 8 c; 9 real 10 a, 11 b; 12 array 13 c, 14 d; 15 begin 16 a := a + 1; 17 s := s + a + b + c[1, 2] + d[1, 2]; 18 d[1, 2] := 2 19 end; 20 21 integer array 22 a[16384 : 16385, - 16383 : - 16382]; 23 integer 24 s; 25 array 26 b[1 : 2, 0 : 2]; 27 a[16384, - 16383] := 3.0; 28 b[1, 2] := a[16384, - 16383]; 29 begin 30 integer array 31 g[1 : b[1, 2], 0 : 2]; 32 s := 0; 33 g[1, 0] := g[2, 0] := g[3, 0] := g[1, 1] := g[2, 1] 34 := g[3, 1] := g[1, 2] := g[2, 2] := g[3, 2] 35 := 1; 36 p(b[1, 2], b[1, 2], g, b); 37 s := s + b[1, 2]; 38 outreal(1, s) 39 end 40 end Compiling... Executing... 14 *** TEST 100 *** Translating... 1 begin 2 comment library 1; 3 integer i, 4 array a[ 1 : 1 ]; 5 i := a[1] := 1; 6 outreal(1, i + a[1]) 7 end test100.alg:4: missing simple variable identifier test100.alg:4: missing semicolon after type declaration test100.alg:7: identifier `a' not declared (see line 5) test100.alg:7: 3 errors detected on the first pass; translation terminated *** TEST 101 *** Translating... 1 begin 2 integer 3 x, 4 y; 5 x := + 2y := - 3; 6 if x < - y then 7 8 end test101.alg:5: missing semicolon, `else', or `end' after statement test101.alg:8: warning: unlabelled dummy statement test101.alg:8: one error detected on the first pass; translation terminated *** TEST 102 *** Translating... 1 begin 2 integer 3 x, 4 y; 5 x :=; 6 end test102.alg:6: invalid use of delimiter `;' as expression operand test102.alg:6: one error detected on the first pass; translation terminated *** TEST 103 *** Translating... 1 begin 2 integer 3 x, 4 y; 5 x := + 3 := y 6 end test103.alg:5: invalid use of delimiter `:=' after expression in assignment statement test103.alg:6: one error detected on the second pass; translation terminated *** TEST 104 *** Translating... 1 begin 2 real 3 w, 4 v; 5 real 6 x, 7 y, 8 z; 9 x := + 6.0; 10 y := - 2.931; 11 z := 4^.2; 12 w := 10, 000; 13 end test104.alg:12: missing semicolon, `else', or `end' after statement test104.alg:13: warning: unlabelled dummy statement test104.alg:13: one error detected on the first pass; translation terminated *** TEST 105 *** Translating... 1 begin 2 real 3 v; 4 v := 3.5#( - 3); 5 end test105.alg:4: real constant `3.5#' incomplete test105.alg:4: missing semicolon, `else', or `end' after statement test105.alg:5: warning: unlabelled dummy statement test105.alg:5: 2 errors detected on the first pass; translation terminated *** TEST 106 *** Translating... 1 begin 2 comment library 1; 3 integer 4 n; 5 real 6 r; 7 n := 2; 8 r := 2.5#n; 9 outreal(1, r); 10 end test106.alg:8: real constant `2.5#' incomplete test106.alg:8: missing semicolon, `else', or `end' after statement test106.alg:10: warning: unlabelled dummy statement test106.alg:10: 2 errors detected on the first pass; translation terminated *** TEST 107 *** Translating... 1 begin 2 real 3 x, 4 y, 5 z; 6 y := 2.0; 7 x := 2.5; 8 z := 5y * (2 + x); 9 end test107.alg:8: missing semicolon, `else', or `end' after statement test107.alg:9: warning: unlabelled dummy statement test107.alg:9: one error detected on the first pass; translation terminated *** TEST 108 *** Translating... 1 begin 2 real 3 y1, 4 y2; 5 y1 := y2 := 1; 6 repeat :; 7 if y1 > 0 then 8 go to stop go to repeat; 9 stop :; 10 end test108.alg:8: missing semicolon, `else', or `end' after statement test108.alg:10: warning: unlabelled dummy statement test108.alg:10: one error detected on the first pass; translation terminated *** TEST 109 *** Translating... 1 begin 2 real 3 x, 4 y, 5 z; 6 x := 6.0; 7 5.0; 8 y := - 2.931; 9 z := 4^.2; 10 end test109.alg:7: invalid use of constant `5.0' test109.alg:10: warning: unlabelled dummy statement test109.alg:10: one error detected on the first pass; translation terminated *** TEST 110 *** Translating... 1 begin 2 integer 3 i.j; 4 i := 2; 5 j := 3; 6 if i * j > i + j then 7 8 end test110.alg:3: invalid use of period test110.alg:3: missing semicolon after type declaration test110.alg:8: warning: unlabelled dummy statement test110.alg:8: identifier `j' not declared (see line 5) test110.alg:8: 3 errors detected on the first pass; translation terminated *** TEST 111 *** Translating... 1 begin 2 real 3 a, 4 x; 5 x := - 10.0; 6 a := (if x < 0 then x - 1 else if x > 1 then x + 1 else 7 x; 8 end test111.alg:8: missing right parenthesis after expression test111.alg:8: warning: unlabelled dummy statement test111.alg:8: one error detected on the first pass; translation terminated *** TEST 112 *** Translating... 1 begin 2 real 3 x; 4 y; 5 z; 6 x := + 6.0; 7 y := - 2.931; 8 z := 4^.2; 9 end test112.alg:9: warning: unlabelled dummy statement test112.alg:9: identifier `y' not declared (see line 4) test112.alg:9: identifier `z' not declared (see line 5) test112.alg:9: 2 errors detected on the first pass; translation terminated *** TEST 113 *** Translating... 1 begin 2 comment library 1; 3 real 4 a, 5 x; 6 x := 0.8; 7 a := (if x >= 0 & x <= 1 then x * x - 3 * x + 4 else 8 0); 9 outreal(a); 10 end test113.alg:10: warning: unlabelled dummy statement test113.alg:10: number of parameters in function designator or procedure statement conflicts with declaration of procedure `outreal' beginning at line 0 test113.alg:10: one error detected on the second pass; translation terminated *** TEST 114 *** Translating... 1 begin 2 integer j,k; 3 array a[0:3]; 4 k := 2; 5 for j := 1 step 1 until k 6 begin 7 i := 0; 8 end; 9 end test114.alg:7: missing `do' delimiter after for list test114.alg:8: warning: unlabelled dummy statement test114.alg:9: warning: unlabelled dummy statement test114.alg:9: identifier `i' not declared (see line 7) test114.alg:9: 2 errors detected on the first pass; translation terminated *** TEST 115 *** Translating... 1 begin 2 integer 3 i, 4 j; 5 real array 6 cat(1 : 15); 7 8 end test115.alg:6: missing left parenthesis after array segment test115.alg:8: warning: unlabelled dummy statement test115.alg:8: one error detected on the first pass; translation terminated *** TEST 116 *** Translating... 1 begin 2 comment library 1; 3 4 comment use of a procedure; 5 6 real 7 a, 8 b, 9 ; 10 procedure example(x, y)result : (r); 11 value 12 x, 13 y; 14 real 15 x, 16 y, 17 r; 18 begin 19 x := x + y; 20 r := x^2 + y^2 21 end; 22 23 a := 1; 24 b := 2; 25 example(a, a + b, r); 26 outreal(1,r) 27 end test116.alg:10: missing simple variable identifier test116.alg:27: identifier `r' not declared (see line 25) test116.alg:27: 2 errors detected on the first pass; translation terminated *** TEST 117 *** Translating... 1 begin 2 switch path := 3 p1, 4 p2; 5 integer 6 n, 7 i; 8 i := 0; 9 label 1 :; 10 i := i + 1; 11 if i = 2 then 12 go to stop; 13 n := 0; 14 go to 15 if p > 0 then 16 path(n) 17 else 18 label 1; 19 p1 := p - 1; 20 p2 := p - 1; 21 stop :; 22 end test117.alg:9: invalid use of delimiter `label' test117.alg:18: invalid use of delimiter `label' as expression operand test117.alg:18: missing semicolon, `else', or `end' after statement test117.alg:22: warning: unlabelled dummy statement test117.alg:22: identifier `p1' not declared (see line 3) test117.alg:22: identifier `p2' not declared (see line 4) test117.alg:22: identifier `p' not declared (see line 15) test117.alg:22: 6 errors detected on the first pass; translation terminated *** TEST 118 *** Translating... 1 begin 2 integer 3 i; 4 real 5 x; 6 array 7 a[0, 3]; 8 i := 1; 9 for x := 1.0, 10 2.0, 11 3.0 do 12 begin 13 a[i] := x; 14 i := i + 1 15 end; 16 end test118.alg:7: missing colon between bound expressions test118.alg:16: warning: unlabelled dummy statement test118.alg:16: one error detected on the first pass; translation terminated *** TEST 119 *** Translating... 1 begin 2 integer 3 k; 4 k := 0; 5 if k = 0 go to finish else 6 k := k + 1; 7 finish :; 8 end test119.alg:5: missing `then' delimiter test119.alg:8: warning: unlabelled dummy statement test119.alg:8: one error detected on the first pass; translation terminated *** TEST 120 *** Translating... 1 begin 2 real 3 x integer i; 4 array 5 a[0 : 3]; 6 i := 0; 7 for x := 1.23, 8 2.34, 9 3.45 do 10 begin 11 a[i] := x; 12 i := i + 1 13 end; 14 end test120.alg:3: missing semicolon after type declaration test120.alg:14: warning: unlabelled dummy statement test120.alg:14: identifier `i' not declared (see line 6) test120.alg:14: 2 errors detected on the first pass; translation terminated *** TEST 121 *** Translating... 1 begin 2 comment library 1; 3 integer 4 i, 5 p; 6 i := 0; 7 for p := 1 step 1 until 4 do 8 begin 9 own integer 10 i; 11 if p = 1 then 12 i := 3 13 else 14 i := 2 * i; 15 begin 16 integer 17 j, 18 i; 19 j := 4; 20 i := 0 21 end; 22 outreal(1, i); 23 end; 24 end Compiling... Executing... 3 6 12 24 *** TEST 122 *** Translating... 1 begin 2 comment library 1; 3 integer 4 i, 5 p; 6 i := 0; 7 for p := 1 step 1 until 4 do 8 begin 9 own integer 10 i; 11 if p = 1 then 12 i := 3 13 else 14 i := 2 * i; 15 begin 16 own integer 17 j, 18 i; 19 i := 0; 20 if i = 0 then 21 j := 4 22 else 23 j := 4 * i; 24 end; 25 outreal(1, i); 26 i := 0; 27 end; 28 i := 0; 29 end Compiling... Executing... 3 0 0 0 *** TEST 123 *** Translating... 1 begin 2 comment library 1; 3 integer 4 i, 5 p; 6 i := 0; 7 for p := 1 step 1 until 4 do 8 begin 9 own integer 10 i; 11 if p = 1 then 12 i := 3 13 else 14 i := 2 * i; 15 begin 16 own integer 17 j, 18 i; 19 if i = 0 then 20 j := 4 21 else 22 j := 4 * i; 23 outreal(1, j); 24 end; 25 i := 0; 26 end; 27 i := 0; 28 end Compiling... Executing... 4 4 4 4 *** TEST 124 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := 1.; 8 outreal(1, x); 9 end test124.alg:7: real constant `1.' incomplete test124.alg:9: warning: unlabelled dummy statement test124.alg:9: one error detected on the first pass; translation terminated *** TEST 125 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := 1.#; 8 outreal(1, x); 9 end test125.alg:7: real constant `1.' incomplete test125.alg:7: real constant `1.#' incomplete test125.alg:9: warning: unlabelled dummy statement test125.alg:9: 2 errors detected on the first pass; translation terminated *** TEST 126 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := #+;outreal(1, x); 8 end test126.alg:7: real constant `#+' incomplete test126.alg:8: warning: unlabelled dummy statement test126.alg:8: one error detected on the first pass; translation terminated *** TEST 127 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := #; 8 outreal(1, x); 9 end test127.alg:7: invalid use of subscripted ten test127.alg:8: invalid use of delimiter `;' as expression operand test127.alg:8: missing semicolon, `else', or `end' after statement test127.alg:9: warning: unlabelled dummy statement test127.alg:9: 3 errors detected on the first pass; translation terminated *** TEST 128 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := .; 8 outreal(1, x); 9 end test128.alg:7: invalid use of period test128.alg:8: invalid use of delimiter `;' as expression operand test128.alg:8: missing semicolon, `else', or `end' after statement test128.alg:9: warning: unlabelled dummy statement test128.alg:9: 3 errors detected on the first pass; translation terminated *** TEST 129 *** Translating... 1 begin 2 3 comment library 1; 4 5 real 6 x; 7 x := #-1000; 8 outreal(1, x); 9 end Compiling... Executing... 0 *** TEST 130 *** Translating... 1 begin 2 3 comment library 1; 4 5 integer 6 i; 7 procedure p; 8 begin 9 integer 10 j; 11 procedure q; 12 if i > 10 then 13 go to l; 14 15 j := i := i + 1; 16 q; 17 outreal(1, j); 18 p; 19 l :; 20 outreal(1, j); 21 end; 22 23 i := 1; 24 p; 25 end Compiling... Executing... 2 3 4 5 6 7 8 9 10 11 10 9 8 7 6 5 4 3 2