Example #1
0
 public void InsRandDate(int count) // int count 갯수만큼 정보가 나옴.
 {
     for (int i = 0; i < count; i++)
     {
         listCar.Add(new Car(rand.getModel(),
                             rand.getColor(),
                             rand.getCompany(),
                             rand.getPrice()));
     }
 }
Example #2
0
 public void insRandData(int count)
 {
     for (int i = 0; i < count; i++)
     {
         listCar.Add(new Car(
                         rand.getModel(),
                         rand.getColor(),
                         rand.getCompany(),
                         rand.getPrice()));
     }
 }
        static void Main(string[] args)
        {
            RandData rand = new RandData();

            Customer[] cs = new Customer[10];

            for (int i = 0; i < cs.Length; i++)
            {
                cs[i] = new Customer(rand.getName(), rand.getTel(),
                                     rand.getAddress(), rand.getModel(), rand.getColor(),
                                     rand.getYear(), rand.getCompany());
                cs[i].printCustomerInfo();
                //Console.WriteLine(cs[i].ToString());
            }
        }