Question: Given: public interface TheInterface { int field = 9 9 ; abstract void method ( ) ; } public abstract class TheAbstract { int field

Given:
public interface TheInterface {
int field =99;
abstract void method();
}
public abstract class TheAbstract {
int field =1983;
abstract void method();
}
public class TheConcrete extends TheAbstract implements TheInterface {
void method(){
System.out.println("balloons");
}
}
Why does compilation fail?
Multiple inheritance of state from field variable
Multiple inheritance of behavior from method()
TheConcrete class using the wrong access modifier for method()
Interfaces cannot have instance fields

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 Programming Questions!