Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
15
Task/Variables/Modula-3/variables-1.mod3
Normal file
15
Task/Variables/Modula-3/variables-1.mod3
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
MODULE Foo EXPORTS Main;
|
||||
|
||||
IMPORT IO, Fmt;
|
||||
|
||||
VAR foo: INTEGER := 5; (* foo is global (to the module). *)
|
||||
|
||||
PROCEDURE Foo() =
|
||||
VAR bar: INTEGER := 10; (* bar is local to the procedure Foo. *)
|
||||
BEGIN
|
||||
IO.Put("foo + bar = " & Fmt.Int(foo + bar) & "\n");
|
||||
END Foo;
|
||||
|
||||
BEGIN
|
||||
Foo();
|
||||
END Foo.
|
||||
1
Task/Variables/Modula-3/variables-2.mod3
Normal file
1
Task/Variables/Modula-3/variables-2.mod3
Normal file
|
|
@ -0,0 +1 @@
|
|||
PROCEDURE Foo(n: INTEGER) =
|
||||
1
Task/Variables/Modula-3/variables-3.mod3
Normal file
1
Task/Variables/Modula-3/variables-3.mod3
Normal file
|
|
@ -0,0 +1 @@
|
|||
PROCEDURE Foo(VAR n: INTEGER) =
|
||||
Loading…
Add table
Add a link
Reference in a new issue