Question: Consider the following code: begin integer m , n; procedure f; begin integer m: = n; print ( in f - - n =

Consider the following code:
begin
integer m, n;
procedure f;
begin
integer m:= n;
print("in f -- n= print("in f -- m =
end;
, n); , m):
procedure g(n: integer);
begin
print("in g -- m
="
, m);
print("in g -- n
=
, n);
f
end;
m : =50;
n :=100; g (1) ; f;
print("in main program --print("in main program -- n
end;
=", m); , n);
What does this program print if the language uses static scoping? What does it pri each frame, show the local variables (including parameters) with their currentvale
points10.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!