小鱼仙倌
2018-11-04 09:42
 public string name;
        public int age;
        private Gender sex;
        public Child(string name, int age, Gender sex)
        {
            this.name = name;
            this.age = age;
            this.sex = sex;        }
				public string name;   
   public int age;        
   public Gender sex;       
   public Child(string name, int age, Gender sex)       
  {           
    this.name = name;           
    this.age = age;           
     this.sex = sex;       
  }
用C#实现封装
78640 学习 · 190 问题
相似问题