Self-Review Exercises
3.1 Fill in the blanks in each of the following:
a) Each class declaration that begins with keyword ______ must be stored in a file that has exactly the same name as the class and ends with the .java filename extension.
b) Keyword ______ in a class declaration is followed immediately by the class’s name.
c) Keyword ______ requests memory from the system to store an object, then calls the corresponding class’s constructor to initialize the object.
d) Each parameter must specify both a(n) ______ and a(n) ______.
e) By default, classes that are compiled in the same directory are considered to be in the same package, known as the ______.
f) Java provides two primitive types for storing floating-point numbers in memory: ______ ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access