adspace


What are the differences between an interface and an abstract class in .net?

Answer Posted / Durgesh Kumar Mishra

An interface defines a contract that a class must implement, but it doesn't provide any implementation. An abstract class can contain both method declarations (abstract methods) and implementation for those methods. An interface can also define properties, events, and indexers, while an abstract class cannot have events or indexers. Multiple classes can implement the same interface, but a class can only inherit from one abstract class.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write the .net syntax for 'while loop'?

1143