Question d’entretien chez Apple

What is the difference between a class, an abstract class, and an interface?

Réponses aux questions d'entretien

Utilisateur anonyme

11 nov. 2013

Class - definition of object Abstract class - partially defined (incomplete - definitions without implementation) Interface - blueprint of class without any implementation

7

Utilisateur anonyme

4 déc. 2014

Class is code and definition of an object An abstract class is a class that is declared abstract—it may or may not include abstract methods. Abstract classes cannot be instantiated, but they can be subclassed. An interface indicates that the inheriting children is capable of doing something (no property)

Utilisateur anonyme

17 janv. 2013

Combining all three, the basic difference is that class can implement more than one interface but can only inherit from only 1 base class.