Question d’entretien chez GE HealthCare

What is the difference between abstract class and interface?

Réponse à la question d'entretien

Utilisateur anonyme

1 août 2025

An abstract class can have both implemented and unimplemented methods, instance variables, and constructors, and is used for code reuse. An interface defines a contract and typically contains abstract methods that must be implemented by classes that inherit it, but it can also include default and static methods with implementations.