Question: pubilc class A extends B { } class B { public B ( String s ) { } } Select ALL that apply The progam

pubilc class A extends B {
}
class B {
public B(String s){
}
}
Select ALL that apply
The progam has a compile error because A does not have a default constructor.
The program has a compile error because the default constructor of A invokes the default constructor of B, but B does not have a default constructor.
The program would compile fine if you add the following constructor into A: A(String s){}
 pubilc class A extends B { } class B { public

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!