Пример #1
0
        static void Main(string[] args)
        {
            Cat anastasia = new Cat("Anastasia");

            Cat.mouseEncounters = 0;
            anastasia.CoughUpFurballs();
            anastasia.Sleep();

            Goldfish goldy = new Goldfish("Goldy");

            goldy.HideFromCat();

            Hamster fred = new Hamster("Fred");

            fred.PlanEscape();

            // Calls Orangutan
            Orangutan tan1 = new Orangutan();

            // Calls Orangutan(int)
            Orangutan tan2 = new Orangutan(100);

            // Calls Orangutan(string)
            Orangutan tan3 = new Orangutan("Stan");
        }
Пример #2
0
		static void Main(string[] args)
		{
			Cat anastasia = new Cat("Anastasia");
            Cat.mouseEncounters = 0;
            anastasia.CoughUpFurballs();
            anastasia.Sleep();

            Goldfish goldy = new Goldfish("Goldy");
            goldy.HideFromCat();

            Hamster fred = new Hamster("Fred");
            fred.PlanEscape();

            // Calls Orangutan
            Orangutan tan1 = new Orangutan();

            // Calls Orangutan(int)
            Orangutan tan2 = new Orangutan(100);

            // Calls Orangutan(string)
            Orangutan tan3 = new Orangutan("Stan");
		}
Пример #3
0
 public void Groom(Orangutan other)
 {
     other.CleanFur();
     other.LookForBugs();
     other.EatBugs();
 }
Пример #4
0
 public void Groom(Orangutan other)
 {
     other.CleanFur();
     other.LookForBugs();
     other.EatBugs();
 }