1
Answer

Passing parameters for multiple constructors usng single obj

harry code

harry code

7y
528
1
Hi,
I want to pass parameters to multiple constructors of different class with the help of a single instance of child class.Can i call them???
My code looks like this:
 
 
class parent1
{
public parent1()
{
}
}
 
class parent2
{
public parent2():parent1
{
}
}
 
class parent3:parent2
{
public parent3()
{
}
}
 
class child
{
static void Main()
{
 child c=new child(10,20,30);
 
Answers (1)