using System;
#region
/*
/// <summary>
/// ????
/// </summary>
class Person
{
//???????
int name;
int height;
//???????
void eat()
{
}
}
class Test
{
static void Main()
{
Person baby = new Person();     //????
baby.name =
Person YaoMin = new Person();   //????
}
}
*/
#endregion
class A
{
//1.?????????????????????????????????????????????????????????
public int i = 100;
public string s = "stone";
public A()
{
Console.WriteLine("constructor");
}
//2.??????????????ι??????г????????????вι??????е?????ι????????????вι??????в????????????????????
public int i;
public string s;
public A()
{
Console.WriteLine("constructor");
i = 100;
s = "stone";
}
public A(int i):this()
{
this.i = i;
}
public A(string s):this()
{
this.s = s;
}
public A(int i?? string s):this()
{
this.i = i;
this.s = s;
}
}
class Test
{
static void Main()
{
//A a = new A();
//Console.WriteLine("i="+a.i);
//Console.WriteLine("s="+a.s);
A a = new A();
Console.WriteLine("first constructor");
Console.WriteLine(a.i);
Console.WriteLine(a.s);
Console.WriteLine();
A a1 = new A(1);
Console.WriteLine("second constructor");
Console.WriteLine(a1.i);
Console.WriteLine(a1.s);
Console.WriteLine();
A a2 = new A("I am third constructor");
Console.WriteLine("third constructor");
Console.WriteLine(a2.i);
Console.WriteLine(a2.s);
Console.WriteLine();
A a3 = new A(3?? "I am the forth constructor");
Console.WriteLine("Forth constructor");
Console.WriteLine(a3.i);
Console.WriteLine(a3.s);
}
}