Q) What is output of the following program? Output: Answer: BWe cannot create an instance of the abstract class in c# programming. Q)What is issue in the below C# class? Answer: A method cannot have a body which is marked as abstract. Below is the correct declaration. The class derived from it will implement the […]
Explain C# Abstract class constructor with Real Time Example
Answer includes C# abstract class constructor with real time example program. An interviewer can also ask it as, can abstract class have constructor in C# program ? If yes, why do we use constructor in abstract class? etc. Answer: Yes, an abstract class can have a constructor, even though abstract class cannot be instantiated. An abstract […]