C# Program PPT
定义一个Person类 using System; public class Person { private string name; private int age; private long ID; public Person(string n, int a, long i) { name = n; age = a; ID = i; } public virtual void Display() { Console.WriteLine(“Name : {0}” , name); Console.WriteLine(“Age : {0}” , age); Console.WriteLine(“ID : {0}” , ID); } }
用户评论