Page 89 - Viva ICSE Computer Studies 8 : E-book
P. 89
Quick Recall
• Java consists of three conditional control structures.
• A selection statement transfers a program control to a location depending on the result of the
conditional expression.
• If control structure can be considered as bidirectional branching.
• If Else If ladder is used to check multiple conditions in a program.
• The Switch statement works as a jumping statement where the control is transferred to a specifi c
case as per the given switch value.
• Looping is a process of executing a block of statements again and again.
• For loop is used when a group of statements is to be executed a specifi c number of times.
• While loop statement in Java programming language repeatedly executes a target statement
as long as a given condition is true.
• Do While loop is similar to the While loop, except that Do While loop is guaranteed to execute
at least one time.
A. Fill in the blanks.
1. A ______________ statement transfers a program control to a location depending on the
result of the conditional expression.
2. If control structure can be considered as ______________.
3. ______________ is used to check multiple conditions in a program.
4. ______________ is a process of executing a block of statements again and again.
5. The ______________ works as a jumping statement.
B. State whether the following statements are true or false.
1. A computer decides about its actions before making decisions. _________
2. Java supports three types of selection statements. _________
3. In a Switch statement, break acts as a terminator. _________
4. Switch condition defi nes whether the loop is to be repeated or it is to be
terminated. _________
5. A while loop repeatedly executes a target statement as long as a given
condition is true. _________
C. Write the output of the following codes.
1. for (int i = 1, i < = 9; i++)
System out.printin (i); _____________________________
77