Self-Review Exercises


(Fill in the Blanks) Fill in the blanks in each of the following statements:

  1. Typically,            statements are used for counter-controlled repetition and            statements for sentinel-controlled repetition.

  2. The dowhile statement tests the loop-continuation condition            executing the loop’s body; therefore, the body always executes at least once.

  3. The            statement selects among multiple actions based on the possible values of an integer variable or expression.

  4. The            statement, when executed in a repetition statement, skips the remaining statements in the loop body and proceeds with the next iteration of the loop.

  5. The            operator can be used to ensure that ...

Get Java How to Program (early objects), 9/e now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.