What is the difference between an interface and a class in Java?
A. An interface can have both abstract and non-abstract methods, while a class can only have non-abstract methods.
B. An interface can only have public static final variables, while a class can have any type of variables.
C. An interface can be implemented by multiple classes, while a class can only extend one class.
D. All of the above.
Answer:C
What is the difference between an interface and a class in Java?
A. An interface can have both abstract and non-abstract methods, while a class can only have non-abstract methods. B. An interface can only have public static final variables, while a class can have any type of variables. C. An interface can be implemented by multiple classes, while a class can only extend one class. D. All of the above.