3.1 a) public. b) class. c) new. d) type, name. e) default package. f) instance variable.

g) float,
double. h) double-precision. i) nextDouble. j)modifier. k) void. l) nextLine. m) java.lang.
n) import declaration. o) floating-point number. p) single-precision. q) %f. r) primitive, reference.
3.2 a) False. By convention, method names begin with a lowercase first letter and all subsequent
words in the name beginwith a capital first letter. b)True. c) True. d)True. e) False. A primitive-type
variable cannot be used to invoke a method—a reference to an object is required to invoke
the object’s methods. f) False. Such variables are called local variables and can be used only in the
method in which they’re declared. g) True. h) False. Primitive-type instance variables are initialized
by default. Each local variable must explicitly be assigned a value. i) True. j) True. k) True. l) False.
Such literals are of type double by default.
3.3 A local variable is declared in the body of a method and can be used only from the point at
which it’s declared through the end of the method declaration. A field is declared in a class, but not
in the body of any of the class’s methods. Also, fields are accessible to all methods of the class.
(We’ll
see an exception to this in Chapter 8, Classes and Objects: A Deeper Look.)
3.4 A parameter represents additional information that a method requires to perform its task.
Each parameter required by a method is specified in the method’s declaration. An argument is the
actual value for a method parameter. When a method is called, the argument values are passed to
the corresponding parameters of the method so that it can perform its task.
3.1 a) public. b) class. c) new. d) type, name. e) default package. f) instance variable. g) float,
double. h) double-precision. i) nextDouble. j)modifier. k) void. l) nextLine. m) java.lang.
n) import declaration. o) floating-point number. p) single-precision. q) %f. r) primitive, reference.
3.2 a) False. By convention, method names begin with a lowercase first letter and all subsequent
words in the name beginwith a capital first letter. b)True. c) True. d)True. e) False. A primitive-type
variable cannot be used to invoke a method—a reference to an object is required to invoke
the object’s methods. f) False. Such variables are called local variables and can be used only in the
method in which they’re declared. g) True. h) False. Primitive-type instance variables are initialized
by default. Each local variable must explicitly be assigned a value. i) True. j) True. k) True. l) False.
Such literals are of type double by default.
3.3 A local variable is declared in the body of a method and can be used only from the point at
which it’s declared through the end of the method declaration. A field is declared in a class, but not
in the body of any of the class’s methods. Also, fields are accessible to all methods of the class.
(We’ll
see an exception to this in Chapter 8, Classes and Objects: A Deeper Look.)
3.4 A parameter represents additional information that a method requires to perform its task.

Such variables are called local variables and can be used only in the method in which they’re declared. When a method is called. q) %f. l) False. k) True. g) float. b)True. g) True. Each parameter required by a method is specified in the method’s declaration. Such variables are called local variables and can be used only in the method in which they’re declared. By convention. (We’ll see an exception to this in Chapter 8. k) True. j)modifier. h) False. n) import declaration. l) nextLine.lang. o) floating-point number. reference.2 a) False. d) type. 3. d)True. 3. d)True.4 A parameter represents additional information that a method requires to perform its task. name. b)True. b) class. Such literals are of type double by default. f) instance variable. the argument values are passed to the corresponding parameters of the method so that it can perform its task. Each local variable must explicitly be assigned a value. p) single-precision. r) primitive. l) nextLine. m) java. An argument is the actual value for a method parameter. p) single-precision.3 A local variable is declared in the body of a method and can be used only from the point at which it’s declared through the end of the method declaration. reference. method names begin with a lowercase first letter and all subsequent words in the name beginwith a capital first letter. e) False. l) False. Also.1 a) public. e) default package. e) False. Classes and Objects: A Deeper Look. h) double-precision. i) True. c) True. n) import declaration. c) new.lang. double. c) True. 3. By convention. Primitive-type instance variables are initialized by default. Primitive-type instance variables are initialized by default. g) True. m) java. 3. j)modifier. q) %f. When a method is called. A primitive-type variable cannot be used to invoke a method—a reference to an object is required to invoke the object’s methods. j) True. h) False. A field is declared in a class.) 3. c) new. b) class. Such literals are of type double by default. f) instance variable.Each parameter required by a method is specified in the method’s declaration. k) void. name. A field is declared in a class. d) type. but not . j) True. An argument is the actual value for a method parameter.2 a) False. g) float. method names begin with a lowercase first letter and all subsequent words in the name beginwith a capital first letter. A primitive-type variable cannot be used to invoke a method—a reference to an object is required to invoke the object’s methods.3 A local variable is declared in the body of a method and can be used only from the point at which it’s declared through the end of the method declaration. f) False. 3.1 a) public. Each local variable must explicitly be assigned a value. 3. i) True. but not in the body of any of the class’s methods. h) double-precision. the argument values are passed to the corresponding parameters of the method so that it can perform its task. o) floating-point number. e) default package. i) nextDouble. i) nextDouble. fields are accessible to all methods of the class. double. f) False. k) void. r) primitive.

. Each parameter required by a method is specified in the method’s declaration. Also.in the body of any of the class’s methods. (We’ll see an exception to this in Chapter 8. fields are accessible to all methods of the class. When a method is called. the argument values are passed to the corresponding parameters of the method so that it can perform its task.4 A parameter represents additional information that a method requires to perform its task. Classes and Objects: A Deeper Look.) 3. An argument is the actual value for a method parameter.