NEW
Font size
WorksheetsSample Test -2
Total questions: 10
Worksheet time: 5mins
Suppose u, v = 10 ,5 before the assignment. What are the values of u and v after the sequence of assignments?
1 u := v
2 v := u
u, v = 5 ,5
u, v = 5 ,10
u, v = 10 ,5
u, v = 10 ,10
If C1 is false and C2 is true, the compound statement
1 if C1
2 S1
3 else
4 if C2
5 S2
6 else
7 S3
executes
S1
S2
S3
none
How many times the loop is iterated?
i := 0
while i ≠ 5
i := i + 1
4
5
6
0
Which of the following is one of the elementary problem solving Techniques?
Decomposition
Control flow
Functions
State
Which is a mix of programming language-like constructs and plain?
Pseudo code
Flowchart
Algorithm
Decomposition
Which translates the program into executable instruction?
Statements
Translator
Linker
None of these
Which of the following is a diagrammatic notation for representing algorithms?
Pseudo code
Programming language
Flow chart
Source Code
How many notations are there for representing algorithms?
1
2
3
4
Testing the loop condition and executing the loop body once is called an
Sequential
Iteration
Alternative
Branching
Which one of the following splits the problem into an exhaustive set of disjoint cases.
Branching
Iterative
Case analysis
Sequential
