Pregunta de entrevista de Confidential

different between abstract and interface ?

Respuesta de la entrevista

Anónimo

15 dic 2024

An abstract class is a class that can't be instantiated on its own; you must inherit from it to use its functionality. It can contain both abstract (unimplemented) and concrete (implemented) methods. An interface is a contract that specifies a set of methods that must be implemented by any class implementing it. They typically do not contain method implementations