ISRO-2007
April 4, 2024ISRO-2007
April 5, 2024Question 41 – ISRO-2007
Consider the following pseudo-code
x:=1;
i:=1;
while (x <= 1000)
begin
x:=2^x;
i:=i+1;
end;
What is the value of i at the end of the pseudo-code?
Correct Answer: B
Question 14 Explanation:
Initialisation: x = 1, i = 1;
Loop: x i
21 2
22 3
24 4
216 5
After this condition becomes false.
Loop: x i
21 2
22 3
24 4
216 5
After this condition becomes false.
4
5
6
7
