Assignment 16 Forloop Ans
Assignment 16 Forloop Ans
a. Yes
b. No
c. Syntax Error
d. Runtime Error
Answer - a. Yes
a. Yes
b. No
c. Syntax Error
d. Runtime Error
Answer - a. Yes
a. Yes
b. No
c. Syntax Error
d. Runtime Error
a. Yes
b. No
c. Syntax Error
d. Runtime Error
Answer - a. Yes
6. The test condition given in the for loop is also known as...
a. Necessary Condition
b. Parent Condition
c. Root Condition
d. None of the above
a. Mature Termination
b. Immature Termination
c. False Termination
d. None of the above
8. The loop terminated by break present inside the body of the for loop is known
as...
a. Mature Termination
b. Immature Termination
c. Pre-Mature Termination
d. None of the above
9. Can we use the keyword continue outside the loop(or without using it inside a
loop)?
a. Yes
b. No, ERROR! MISPLACED CONTINUE! (In Turbo)
c. Yes, only in Turbo
d. Yes, only in modern compiler
10. If we use continue within the loop, it transfers the control to...
a. Statement Part
b. Parent Condition Part
c. Current Condition Part
d. First Line of the loop body
11. If we use continue within the for loop then the termination will be...
a. Mature Termination
b. Immature Termination
c. Pre-Mature Termination
d. None of the above
a. 9 10
b. 10 10
c. 10 11
d. 9 9
Answer - c. 10 11
a. 3 7
b. 4 4
c. 9 10
d. 4 10
Answer - b. 4 4
a. 81
b. 729
c. 27
d. 0
Answer - a. 81
a. -2 11
b. 4 4
c. 0 11
d. 2 11
Answer - a. -2 11
a. 0
b. 2
c. 4
d. 5
Answer - c. 4
a. -1 2 -7
b. -1 -2 -7
c. 1 -2 -7
d. None of these
Answer - b. -1 -2 -7
Answer - a. 6 4 9 7 12