What is an interface in C#?
Answers
Answered by
0
Interface, in C#, is a code structure that defines a contract between an object and its user.In general, an interface is used to describe a set of related functionalities that can be implemented in a class or struct. It enables a class to inherit multiple behaviors defined in multiple interfaces.
Answered by
0
- Interface in C# is a blueprint of a class. It is like abstract class because all the methods which are declared inside the interface are abstract methods. It cannot have method body and cannot be inst.antiated. It is used to achieve multiple inheritance which can't be achieved by class.
Similar questions
English,
6 months ago
Math,
6 months ago
Hindi,
6 months ago
Computer Science,
11 months ago
Computer Science,
11 months ago
English,
1 year ago
Physics,
1 year ago
English,
1 year ago