Question: Which constructors can be inserted at (1) in MySub without causing a compiletime error? Select the one correct answer. (a) MySub() {} (b) MySub(int count)
Which constructors can be inserted at (1) in MySub without causing a compiletime error?

Select the one correct answer.
(a) MySub() {}
(b) MySub(int count) { this.count = count; }
(c) MySub(int count) { super(); this.count = count; }
(d) MySub(int count) { this.count = count; super(count); }
(e) MySub(int count) { this(count, count); }
(f) MySub(int count) { super(count); this(count, 0); }
class MySuper { int number; MySuper (int i) { number = i; } } class MySub extends MySuper { int count; MySub (int count, int num) { super (num); this.count = count; } // (1) INSERT CONSTRUCTOR HERE }
Step by Step Solution
3.53 Rating (156 Votes )
There are 3 Steps involved in it
e The class MySuper does not have a noargument constructor This means tha... View full answer
Get step-by-step solutions from verified subject matter experts
