private int MaxMove(Board board)
        {
            var winner = board.GetWinner();

            if (winner != 0 || board.IsFilled())
            {
                if (winner == 0)
                    return 0;
                if (winner == Value)
                    return Board.SIZE;
                return -Board.SIZE;
            }

            var moves = board.GetPossibleMoves();

            // Look for best move
            int bestMove = -(Board.SIZE + 1);

            foreach (Move move in moves)
            {
                var newBoard = board.Copy();
                newBoard.AddMove(move, Value);

                var grade = MinMove(newBoard);
                grade = decreaseOneStep(grade);
                if (grade > bestMove)
                    bestMove = grade;
            }

            return bestMove;
        }
        private int MinMove(Board board)
        {
            var winner = board.GetWinner();

            if (winner != 0 || board.IsFilled())
            {
                if (winner == 0)
                    return 0;
                if (winner == Value)
                    return Board.SIZE;
                return -Board.SIZE;
            }

            var enemyValue = (this.Value == 1) ? 2 : 1;
            var moves = board.GetPossibleMoves();

            int worstMove = Board.SIZE + 1;

            foreach (Move move in moves)
            {
                var newBoard = board.Copy();
                newBoard.AddMove(move, enemyValue);

                var grade = MaxMove(newBoard);
                grade = decreaseOneStep(grade);
                if (grade < worstMove)
                    worstMove = grade;
            }

            return worstMove;
        }