public static void BuildUI(string[] args)
        {
            const int RIGHT_ARGS = 1;

            switch (args.Length)
            {
            case RIGHT_ARGS:
            {
                try
                {
                    Board board = Board.Create(int.Parse(args[1]), int.Parse(args[2]));
                    UIBoard.DrowBoard(board);
                }
                catch (ArgumentException e)
                {
                    Console.WriteLine(e.Message);
                }
                break;
            }

            default:
            {
                Instruction();
                break;
            }
            }
        }
Exemple #2
0
 static void Main(string[] args)
 {
     UIBoard.BuildUI(args);
 }