psuh
This commit is contained in:
@ -1 +1,30 @@
|
||||
(* TODO *)
|
||||
(* TEST: [-asc -tc -cg -ir] *)
|
||||
|
||||
#include "std.alpha"
|
||||
|
||||
function entry : string2integer
|
||||
function Fib : integer2integer
|
||||
|
||||
Fib(i) := {
|
||||
[ Boolean: a ; Boolean: b ; Boolean: c]
|
||||
if( i = 0 ) then {
|
||||
return 7;
|
||||
} else {
|
||||
i := i;
|
||||
}
|
||||
b := b | (a & c);
|
||||
b := 2 < 3;
|
||||
if(i = 1) then {
|
||||
return 1;
|
||||
} else {
|
||||
return i + Fib(i - 1);
|
||||
}
|
||||
}
|
||||
|
||||
entry (arg) := {
|
||||
[ integer: x; integer: y ]
|
||||
x := 2;
|
||||
x := Fib(2);
|
||||
y := printInteger(Fib(2));
|
||||
return 1;
|
||||
}
|
||||
|
@ -5,6 +5,8 @@ function entry: string2integer
|
||||
entry (arg) := {
|
||||
[integer: x; string: s; character: c; integer: result]
|
||||
|
||||
result := printS("hello world");
|
||||
|
||||
s := inS(1);
|
||||
result := printS(s);
|
||||
|
||||
|
Reference in New Issue
Block a user