A directory of Objective Type Questions covering all the Computer Science subjects. Here you can access and discuss Multiple choice questions and answers for various compitative exams and interviews.

Discussion Forum

Que. Consider the following program

Program P2
var n: int:
procedure W(var x: int)
begin
x=x+1;
print x;
end

procedure D
begin
var n: int;
n=3;
W(n);
end
begin //beginP2
n=10;
D;
end

If the language has dynamic scoping and parameters are passed by reference, what will be printed by the program?
a. 10
b. 11
c. 3
d. None of the above
Answer:None of the above
Confused About the Answer? Ask for Details Here
Know Explanation? Add it Here

Similar Questions: