HP SunSoft Pascal 4.0 User Manual
Page 96
Advertising
72
Pascal 4.0 User’s Guide
4
Here is a program unit that declares a variable:
Here is a module unit that declares a variable with the same name:
program program_unit3 (output);
var
x : integer;
procedure say_hello; external;
begin
for x := 1 to 5 do say_hello
end.
module module_unit3;
var
x : integer;
procedure say_hello;
begin
writeln ('Hello, world for the', x, ' time.')
end;
Advertising