Review Questions |
6.9 |
Given the following code, which of these constructors can be added to MySubclass without causing a compile-time error?
class MySuper { int number; MySuper(int i) { number = i; } } class MySub extends MySuper { int count; MySub(int cnt, int num) { super(num); count=cnt; } // INSERT ADDITIONAL CONSTRUCTOR HERE } Select the one correct answer.
|
6.10 |
Which statement is true?
Select the one correct answer.
|
Get Programmer's Guide to Java™ Certification, A: A Comprehensive Primer, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.