class program
{
static void Main(string[] arg)
{
numberteller obj = new number teller();
}
console.Writeline(obj.tellCons());
Console.ReadLine();
}
class numberteller
{
string WhicConscalled;
public numberteller()
{
WhicConscalled= "null constuctor called";
}
public numberteller (int a)
{
WhicConscalled = "int constructor called";
}
public numberteller(double a)
{
WhicConscalled = "double constructor called";
}
public string tellcons()
{
return WhicConscalled;
}
{
static void Main(string[] arg)
{
numberteller obj = new number teller();
}
console.Writeline(obj.tellCons());
Console.ReadLine();
}
class numberteller
{
string WhicConscalled;
public numberteller()
{
WhicConscalled= "null constuctor called";
}
public numberteller (int a)
{
WhicConscalled = "int constructor called";
}
public numberteller(double a)
{
WhicConscalled = "double constructor called";
}
public string tellcons()
{
return WhicConscalled;
}

0 comments:
Post a Comment