Files
IBAFLang/IBAF-Tests/IBAF-1/initialiseTest.fct

69 lines
1.4 KiB
Plaintext

initialise-binding scope
(collateral
(bind
("x",
allocate-variable
(integers)),
map
( ),
bind
("y",
allocate-variable
(integers)),
map
( ),
map
( )),
sequential
(initialise-variable
(bound "x",
int-mul
(decimal-natural
("10"),
decimal-natural
("10"))),
print
(to-string assigned bound
"x",
"
"),
initialise-variable
(bound "y",
decimal-natural
("5")),
if-else
(true,
scope
(collateral
(bind
("y",
allocate-variable
(integers)),
map
( ),
map
( )),
sequential
(initialise-variable
(bound "y",
int-mul
(assigned bound
"x",
assigned bound
"x")),
print
(to-string assigned bound
"x",
"
"),
print
(to-string assigned bound
"y",
"
"))),
null),
print
(to-string assigned bound
"y",
"
")))