Quiz: An Exercise on Variable Names
What is the variable name?
Picture rocket = new Picture("mariner4.jpg");
Picture
rocket
new
mariner4
Picture
is the class of the object that is stored in the rocket
variable. The variable is initialized with the object obtained by calling new Picture("mariner4.jpg")
.