Self-Review Exercises

A.1 Fill in the blanks in each of the following statements:

a) A(n) ____________ begins the body of every method, and a(n) ____________ ends the body of every method.

b) The ____________ statement is used to make decisions.

c) ____________ begins an end-of-line comment.

d) _____________, ____________ and ____________ are called white space.

e) ____________ are reserved for use by Java.

f) Java applications begin execution at method ____________.

g) Methods _____________, ____________ and ____________ display information in a command window.

A.2 State whether each of the following is true or false. If false, explain why.

a) Comments cause the computer to print the text after the // on the screen when the program executes. ...

Get Android™ How to Program, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.