重载public Primes ():this(2,100)

当构造函数有多个重载的时候 想通过默认构造函数调用其他的重载的构造函数的话 就可以用:运算符
public Primes():this(2, 100)
{
//code

}
public Primes(int a, int b) //重载的
{
//code
}
string s = default(string);//表示的是获取某种类型的默认值
posted @ 2014-04-23 16:06  醉孟子  阅读(341)  评论(0编辑  收藏  举报