Ejemplo n.º 1
0
 public static void Main()
 {
     string Q = "y";
     do
     {
         UIJumble uJ = new UIJumble();
         uJ.DisplayWelcome();
         uJ.Play();
         Console.WriteLine();
         Console.WriteLine("Do you wish to play again? (y/n)");
         Q = Console.ReadLine();
         if (Q != "y" && Q != "Y")
             break;
         Console.Clear();
     } while (true);
 }
        public void PlayAgain()
        {
            string playAgain = "Y";

            do
            {
                UIJumble newUI = new UIJumble();
                newUI.DisplayWelcome();
                newUI.Play();

                Console.WriteLine("Do you like to Play again ? :");
                playAgain = Console.ReadLine();

                if (playAgain.Length > 0)
                    playAgain = playAgain.Substring(0, 1);
                playAgain = playAgain.ToUpper();
            }
            while (playAgain == "Y");
        }