Exam 7: Inheritance
Exam 1: Getting Started45 Questions
Exam 2: Console Input and Output29 Questions
Exam 3: Flow of Control44 Questions
Exam 4: Defining Classes I45 Questions
Exam 5: Defining Classes II46 Questions
Exam 6: Arrays46 Questions
Exam 7: Inheritance43 Questions
Exam 8: Polymorphism and Abstract Classes43 Questions
Exam 9: Exception Handling45 Questions
Exam 10: File IO46 Questions
Exam 11: Recursion44 Questions
Exam 12: Uml and Patterns22 Questions
Exam 13: Interfaces and Inner Classes32 Questions
Exam 14: Generics and the Arraylist Class32 Questions
Exam 15: Linked Data Structures43 Questions
Exam 16: Collections,maps,and Iterators44 Questions
Exam 17: Swing I37 Questions
Exam 18: Swing II31 Questions
Exam 19: Java Never Ends26 Questions
Exam 20: Applets25 Questions
Select questions type
Inheritance refers to a very specialized form of a class.
Free
(True/False)
4.9/5
(30)
Correct Answer:
False
What are the different ways in which you can check the class of an Object?
Free
(Essay)
4.8/5
(33)
Correct Answer:
The method getClass)as well as the operator instanceof may be used to check the class type of an Object.
When you define a derived class,you give only the added instance variables and the added methods as well as all the methods from the base class.
Free
(True/False)
4.9/5
(44)
Correct Answer:
False
Define a derived class to represent an alarm clock.Use the Clock class,created in number 2 above,as your base class.
(Essay)
4.9/5
(44)
Define a base class to represent a Clock.Your class should have instance variables for hours,minutes and seconds.
(Essay)
4.8/5
(30)
Create a test driver to test the functionality of your Rectangle class created in number 14 above.
(Essay)
4.9/5
(37)
You may substitute the keyword this for super)to call a constructor of the derived class.
(True/False)
4.9/5
(45)
What is an "is a" relationship? How does it apply to the world of objects?
(Essay)
4.8/5
(37)
Explain the difference between method overloading and method overriding.
(Essay)
4.8/5
(38)
If an instance variable is not modified by public,protected or private then it is said to have:
(Multiple Choice)
4.8/5
(39)
The class __________ is an ancestor class of all Java classes.
(Multiple Choice)
4.8/5
(32)
Showing 1 - 20 of 43
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)