Exam 6: A Second Look at Classes and Objects
Exam 1: Introduction to Computers and Java40 Questions
Exam 2: Java Fundamentals40 Questions
Exam 3: A First Look at Classes and Objects40 Questions
Exam 4: Decision Structures42 Questions
Exam 5: Loops and Files40 Questions
Exam 6: A Second Look at Classes and Objects40 Questions
Exam 7: Arrays and the Arraylist Class40 Questions
Exam 8: Text Processing and Wrapper Classes40 Questions
Exam 9: Inheritance40 Questions
Exam 10: Exceptions and Advanced File Io40 Questions
Exam 11: Java-Fx: Gui Programming and Basic Controls40 Questions
Exam 12: Java-Fx: Advanced Controls40 Questions
Exam 13: Java-Fx: Graphics, Effects, and Media40 Questions
Exam 14: Recursion24 Questions
Exam 15: Databases40 Questions
Select questions type
If you write a toString method for a class, Java will automatically call the method any time you concatenate an object of the class with a string.
(True/False)
4.8/5
(33)
Enumerated types have the __________ method which returns the position of an enum constant in the declaration list.
(Multiple Choice)
4.8/5
(24)
You cannot use the fully-qualified name of an enum constant for
(Multiple Choice)
4.8/5
(32)
An instance of a class does not have to exist in order for values to be stored in a class's static fields.
(True/False)
4.8/5
(34)
If the following is from the method section of a UML diagram, which of the statements shown is true? + equals(object2:Stock) : boolean
(Multiple Choice)
4.8/5
(34)
The names of the enum constants in an enumerated data type must be enclosed in quotation marks.
(True/False)
4.8/5
(38)
When you make a copy of the aggregate object and of the objects that it references,
(Multiple Choice)
4.8/5
(40)
Of the following, which would be considered the no-arg constructor for the Rectangle class?
(Multiple Choice)
4.8/5
(38)
The "has a" relationship is sometimes called a(n) __________ because one object is part of a greater whole.
(Multiple Choice)
4.7/5
(33)
Given the following method header, what will be returned from the method? public Rectangle getRectangle()
(Multiple Choice)
4.9/5
(40)
When a method in the __________ class returns a reference to a field object, it should return a reference to a copy of the field object to prevent security holes.
(Multiple Choice)
4.8/5
(40)
When a method's type is an object, what is actually returned by the calling program?
(Multiple Choice)
4.8/5
(33)
Assume the class BankAccount has been created and the following statement correctly creates an instance of the class. BankAccount account = new BankAccount(5000.00);
What is true about the following statement?
System.out.println(account);
(Multiple Choice)
4.9/5
(35)
If object1 and object2 are objects of the same class, to make object2 a copy of object1
(Multiple Choice)
4.7/5
(30)
Showing 21 - 40 of 40
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)