Exemple #1
0
        static void Main(string[] args)
        {
            Console.WriteLine("A long long time ago, in a galaxy far away...");

            var mum = new Mum("Leila");
            var dad = new Dad("Han Solo");

            mum.MakeBaby(dad, "Kylo Ren");
            mum.Child.StartCrying();

            Console.Read();
        }
Exemple #2
0
        static void Main(string[] args)
        {
            Console.WriteLine("A long long time ago, in a galaxy far away...");

            var mum = new Mum("Leila");
            var dad = new Dad("Han Solo");

            mum.MakeBaby(dad, "Kylo Ren");
            mum.Child.StartsCrying();
            mum.Child.StartsCrying();
            mum.Child.StartsCrying();
            mum.Child.Cries += b =>
            {
                Console.WriteLine($"The Force feels the evil of {mum.Child.Name}");
                Console.WriteLine($"The Force balances the evil with the birth of Rey");
            };
            mum.Child.StartsCrying();

            Console.Read();
        }