The . (dot) operator is also called the member access operator.
correct | True | |
False |
Question 2 |
Primitive type variables directly store data into their memory space.
cottect | True | |
False |
Question 3 |
The new operator can be used to create a class object.
correct | True | |
False |
Question 4 |
Members of a class consist of packages, methods, and libraries.
True | ||
correct | False |
Question 5 |
The following statements creates alpha to be a two-dimeansional array of 25 rows and 10 columns.
int[][] alpha = new int[25][10];
correct | True | |
False |
Question 6 |
A set method of a class first accesses the values of the data members of the class and then changes the values of the data members.
True | ||
False |
Question 7 |
In the class String, the substring method extracts a string from within another string.
True | ||
correct | False |
Question 8 |
In column processing, a two-dimensional array is processed one column at a time.
correct | True | |
False |
Question 9 |
Arrays have a fixed number of components.
correct | True | |
False |
Question 10 |
When writing output to a file, if the file is not closed at the end of the program, you may not be able to view your output properly.
correct | True | |
False |
Question 11 |
indexOf(char ch) is a method in the class String.
correct | True | |
False |
Question 12 |
The DecimalFormat class can be used only to format the output of decimal numbers.
True | ||
correct | False |
Question 13 |
The modifier static in the heading specifies that the method can be invoked by using the name of the class.
correct | True | |
False |
Question 14 |
A class can have only one constructor.
True | ||
correct | False |
Question 15 |
A constructor has no type and is therefore a void method.
True | ||
correct | False |
Question 16 |
Every object has access to a reference to itself.
correct | True | |
False |
Question 17 |
The built-in operation that is valid for classes is the dot operator (.).
True | ||
False |
Question 18 |
The word new is an operator.
True | ||
False |
Question 19 |
Suppose that you have the following declarations.
int[] alpha = new int[100];
int[][] beta = new int[25][4];
In this declaration, the array alpha has more components than the array beta.
True | ||
False |
Question 20 |
If the specified output file does not exist, the computer prepares an empty file for output.
True | ||
False |
Question 21 |
String variables are primitive variable types.
True | ||
False |
Question 22 |
The method length in the class String returns the number of characters in the string not including whitespace characters.
True | ||
False |
Question 23 |
The + operator is used to instantiate a class.
True | ||
False |
Question 24 |
In row processing, a two-dimensional array is processed one row at a time.
True | ||
False |
Question 25 |
If a member of a class is a method, it can (directly) access any member of the class.
True | ||
False |
Question 26 |
Given String name; the value of name is directly stored in its memory space.
True | ||
False |
Question 27 |
If the specified output file does not exist, you will get a FileNotFoundException.
True | ||
False |
Question 28 |
A get method of a class changes the values of the data members of the class.
True | ||
False |