Exemplo n.º 1
0
        static void Main(string[] args)
        {
            Terning t1 = new Terning();

            Console.WriteLine($"Start værdi t1 [{t1.Værdi}]");
            //Console.Write("Press any key to continue . . . ");
            //Console.ReadKey();
            t1.Ryst();
            //Console.WriteLine();
            Console.WriteLine($"værdi efter ryst t1 [{t1.Værdi}]");

            LudoTerning t2 = new LudoTerning();

            Console.WriteLine($"Start værdi t2 [{t2.Værdi}]");
            //Console.Write("Press any key to continue . . . ");
            //Console.ReadKey();
            t2.Ryst();
            //Console.WriteLine();
            Console.WriteLine($"værdi efter ryst t2 [{t2.Værdi}]");
            Console.WriteLine($"Er Globus {t2.ErGlobus()}");
            Console.WriteLine($"Er Stjerne {t2.ErStjerne()}");

            if (System.Diagnostics.Debugger.IsAttached)
            {
                Console.Write("Press any key to continue . . . ");
                Console.ReadKey();
            }
        }
Exemplo n.º 2
0
        static void Main(string[] args)
        {
            Terning t = new Terning();

            t.Skriv();
            t.Ryst();
            t.Skriv();

            LudoTerning l = new LudoTerning();

            l.Skriv();
            Console.WriteLine(l.ErGlobus());
            Console.WriteLine(l.ErStjerne());

            // Hold console åben ved debug
            if (System.Diagnostics.Debugger.IsAttached)
            {
                Console.Write("Press any key to continue . . . ");
                Console.ReadKey();
            }
        }