MCQ
What will be printed after this dry run? X = 2; X = X + 3; PRINT X.
Unit-2 Computational Thinking and Algorithms
A
2
B
3
C
5
D
23
Explanation
X starts at 2, becomes 2+3=5, and 5 is printed.
Related MCQs
Which of the following best describes iteration in an algorithm?
Unit-2 Computational Thinking and Algorithms
View
A named storage location in a program whose value can change during execution is called a:
Unit-2 Computational Thinking and Algorithms
View
In the IPO model, entering the marks of students into a program is an example of:
Unit-2 Computational Thinking and Algorithms
View
The OR operator gives TRUE when:
Unit-2 Computational Thinking and Algorithms
View
Which of the following is TRUE about pseudocode?
Unit-2 Computational Thinking and Algorithms
View
Sum = 0; FOR count = 1 TO 3; Sum = Sum + count; NEXT count; PRINT Sum. What is the output?
Unit-2 Computational Thinking and Algorithms
View