JAVA Programming :: Objects and Classes - Discussion
Home > JAVA Programming > Objects and Classes > MCQs Questions Discussion
24 / 30
Choose the correct option.
class A {
A(String s) {
}
A() {
}
}
class B extends A {
B() { }
B(String s) {
super(s);
}
void test() {
// insert code here
}
}
Which of the below code can be insert at line 7 to make clean compilation ?
AA a = new B();
BA a = new B(5);
CA a = new A(String s);
DAll of the above
Answer: Option (Login/Signup)
Show Explanation
Asked In ::
No Discussion on this question yet!