algorithm-in-python/parser/PL0-compiler/test/txt/closure.txt

14 lines
221 B
Plaintext
Raw Normal View History

2019-03-15 16:37:02 +08:00
var a =1;
func foo(a)
print("[in function foo ] a=%d",a);
func bar(a)
begin
print("[in function bar ] a=%d",a);
foo(4);
end;
begin
print("[in function main] a=%d",a);
foo(2);
bar(3)
end.