procedure First is
begin
Put(X); -- Print X
New_Line; -- Print a newline character
end First;
procedure Second is
X: integer;
procedure Third is
X: Integer;
begin -- Third
x := 99;
First;
end Third;
begin -- Second
x := 88;
Third;
end Second;
begin -- Example
x := 77;
First;
Second;
end Example;
a) What will be printed by this program if we assume static scope?
b) What will be printed by this program if we assume dynamic scope?
"assignmentexpert.com" is professional group of people in Math subjects! They did assignments in very high level of mathematical modelling in the best quality. Thanks a lot
Comments
Leave a comment