Exemplo n.º 1
0
        static void Main(string[] args)
        {
            Ifactory    factory = new UndergraduateFactory();
            Nightingale student = factory.CreateNiahtingale();

            student.BuyRice();
            student.Sweep();
            student.Wash();
        }
Exemplo n.º 2
0
        static void Main(string[] args)
        {
            IFactory    factory = new UngraduateFactory();
            Nightingale Student = factory.CreateNightingale();

            Student.Sweep();
            Student.Wash();
            Student.BuyRice();
            Console.Read();
        }