How do you implement multiple inheritance in .NET?
Answer Posted / shadab
To implement multiple inheritance in .net we will have to
use Interface...
see the below program..
using System;
interface Ifirst
{
void display();
}
class use:Ifirst
{
public void display()
{
Console.WriteLine("This is a method");
}
public static void Main()
{
use u=new use();
u.display();
}
}
----------
for more help visit my blog
http://www.shadab-programminghelp.blogspot.com
| Is This Answer Correct ? | 8 Yes | 0 No |
Post New Answer View All Answers
Illustrate the process of code compilation in c#?
What are the types of parameters in c#?
Is class reference type c#?
Explain the access modifiers in c#?
What is the difference between the debug class and trace class? Documentation looks the same.
Explain dataset.acceptchanges method in .net?
What is the use of inheritance in c#?
How many types of interface are there in c#?
Explain the 3 types of properties in c# with an example?
Hi Friends, I am going through Siemens Interview Procedure from last 1+1/2 months. I went through 1 written + 2 Technical + 1 Managerial Round process after which I got call from HR informing that "you are selected and we would like to meet you for HR round". HR round was very nominal compared to MR. HR Round last for hardly 5 mins. They told me that you will get the final result on Friday. Still I have not received any feedback from them. Please help!!!
Can var be null c#?
What is a struct in C#?
What are the steps to make an assembly to public?
What is stringwriter c#?
Where do we use static class in c#?