 that represents a single signer's public key.
#[derive(Copy, Clone, PartialEq)]
pub struct Public<C>(pub(super) <C::Group as Group>::Element)
where
    C: Ciphersuite;

impl<C> Public<C>
where
    C: Ciphersuite,
{
    /// Deserialize from bytes
    pub fn from_bytes(bytes: <C::Group as Group>::Serialization) -> Result<Self, Error> {
        <C::Group as Group>::deserialize(&bytes).map(|element| Self(element))
    }

    /// Serialize [`Public`] to bytes
    pub fn to_bytes(&self) -> <C::Group as Group>::Serialization {
        <C::Group as Group>::serialize(&self.0)
    }
}

impl<C> Debug for Public<C>
where
    C: Ciphersuite,
{
    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        f.debug_tuple("Public")
            .field(&hex::encode(self.to_bytes()))
            .finish()
    }
}

impl<C> From<Secret<C>> for Public<C>
where
    C: Ciphersuite,
{
    fn from(secret: Secret<C>) -> Public<C> {
        Public(<C::Group as Group>::generator() * secret.0 as Scalar<C>)
    }
}

/// A [`Group::Element`] that is a commitment to one coefficient of our secret polynomial.
///
/// This is a (public) commitment to one coefficient of a secret polynomial used for performing
/// verifiable secret sharing for a Shamir secret share.
#[derive(Clone, Copy, PartialEq)]
pub(super) struct CoefficientCommitment<C: Ciphersuite>(pub(super) <C::Group as Group>::Element);

/// Contains the commitments to the coefficients for our secret polynomial _f_,
/// used to generate participants' key shares.
///
/// [`VerifiableSecretSharingCommitment`] contains a set of commitments to the coefficients (which
/// themselves are scalars) for a secret polynomial f, where f is used to
/// generate each ith participant's key share f(i). Participants use this set of
/// commitments to perform verifiable secret sharing.
///
/// Note that participants MUST be assured that they have the *same*
/// [`VerifiableSecretSharingCommitment`], either by performing pairwise comparison, or by using
/// some agreed-upon public location for publication, where each participant can
/// ensure that they received the correct (and same) value.
#[derive(Clone)]
pub struct VerifiableSecretSharingCommitment<C: Ciphersuite>(
    pub(super) Vec<CoefficientCommitment<C>>,
);

/// A secret share generated by performing a (t-out-of-n) secret sharing scheme.
///
/// `n` is the total number of shares and `t` is the threshold required to reconstruct the secret;
/// in this case we use Shamir's secret sharing.
///
/// As a solution to the secret polynomial _f_ (a 'point'), the `index` is the x-coordinate, and the
/// `value` is the y-coordinate.
#[derive(Clone, Zeroize)]
pub struct SecretShare<C: Ciphersuite> {
    /// The participant index of this [`SecretShare`].
    pub index: u16,
    /// Secret Key.
    pub value: Secret<C>,
    /// The commitments to be distributed among signers.
    pub commitment: VerifiableSecretSharingCommitment<C>,
}

impl<C> SecretShare<C>
where
    C: Ciphersuite,
{
    /// Gets the inner [`Secret`] share value.
    pub fn secret(&self) -> &Secret<C> {
        &self.value
    }

    /// Verifies that a secret share is consistent with a verifiable secret sharing commitment.
    ///
    /// This ensures that this participant's share has been generated using the same
    /// mechanism as all other signing participants. Note that participa


.alias then
		server_name=s.alias
	elseif s.server and s.server_port then
		server_name= "%s:%s" %{s.server, s.server_port}
	end
	iret=luci.sys.call(" ipset add ss_spec_wan_ac " .. s.server .. " 2>/dev/null")
	socket = nixio.socket("inet", "stream")
	socket:setopt("socket", "rcvtimeo", 3)
	socket:setopt("socket", "sndtimeo", 3)
	ret=socket:connect(s.server,s.server_port)
	if  tostring(ret) =


需要重新加载');
        return;
      }

      // 为防止方法返回void类型导致的错误，创建一个Completer
      final completer = Completer<void>();

      // 定义一个订阅变量
      StreamSubscription<editor_bloc.EditorState>? subscription;

      // 监听状态变化，以便在加载完成时完成Future
      subscription = editorBloc.stream.listen((state) {
        if (state is editor_bloc.EditorLoaded && !state.isLoading) {
          // 检查章节是否已有场景
          bool nowHasScenes = false;
          for (final act in state.novel.acts) {
            if (act.id == targetActId) {
              for (final chapter in act.chapters) {
                if (chapter.id == chapterId) {
                  nowHasScenes = chapter.scenes.isNotEmpty;
                  break;
                }
              }
              break;
            }
          }

          if (nowHasScenes) {
            AppLogger.i('EditorScreenController', '章节 $chapterId 场景已成功加载');
            subscription?.cancel();
            if (!completer.isCompleted) completer.complete();
          }
        }
      });

      // 设置超时，防止无限等待
      Future.delayed(const Duration(seconds: 5), () {
        if (!completer.isCompleted) {
          AppLogger.w('EditorScreenController', '预加载章节场景超时');
          subscription?.cancel();
          completer.complete(); // 即使超时也完成Future
        }
      });

      // 使用参数preventFocusChange=true确保不会改变焦点
      editorBloc.add(editor_bloc.LoadMoreScenes(
        fromChapterId: chapterId,
        actId: targetActId,
        direction: 'center',
        chaptersLimit: 5,
        preventFocusChange: true, // 设置为true避免改变焦点
        loadFromLocalOnly: false  // 从服务器加载，确保有最新数据
      ));

      // 返回Future，以便调用者等待加载完成
      return completer.future;
    }
  }

  // 🚀 修改：切换Plan视图使用EditorBloc的模式切换
  void togglePlanView() {
    AppLogger.i('EditorScreenController', '切换Plan视图，当前状态: $isPlanViewActive');

    // 切换状态
    isPlanViewActive = !isPlanViewActive;

    // 如果激活Plan视图，关闭剧情推演视图
    if (isPlanViewActive) {
      isNextOutlineViewActive = false;
      // 🚀 修改：使用EditorBloc切换到Plan模式
      editorBloc.add(const editor_bloc.SwitchToPlanView());
    } else {
      // 🚀 修改：使用EditorBloc切换到Write模式（包含无感刷新）
      editorBloc.add(const editor_bloc.SwitchToWriteView());
    }

    // 记录日志
    AppLogger.i('EditorScreenController', '切换后的Plan视图状态: $isPlanViewActive');

    notifyListeners();
  }

  // 切换剧情推演视图
  void toggleNextOutlineView() {
    AppLogger.i('EditorScreenController', '切换剧情推演视图，当前状态: $isNextOutlineViewActive');

    // 切换状态
    isNextOutlineViewActive = !isNextOutlineViewActiv


;		// output bits are quadruple input bits

	for (i = 0; i < bytes; i++) {
		uint8_t gray;
		uint8_t twoPixels = *from++;
		uint16_t pixela, pixelb;

		gray = (twoPixels >> 2) & 0x3C;
		gray |= gray >> 4;				// 6 bits of gray
		pixela = gray >> 1;				// 5 bita of gray
		pixela |= (pixela << 11) | (gray << 5);
		pixela = (pixela >> 8) | (pixela << 8);

		gray = (twoPixels << 2) & 0x3C;
		gray |= gray >> 4;
		pixelb = gray >> 1;
		pixelb |= (pixelb << 11) | (gray << 5);
		pixelb = (pixelb >> 8) | (pixelb << 8);

		*to++ = (pixelb << 16) | pixela;
	}

	return bytes;		// input bytes consumed
}

uint32_t IRAM_ATTR modSpiLoadBufferCLUT16To16BE(uint8_t *data, uint32_t bytes, uint32_t *bitsOut)
{
	uint16_t *clut16_t = gCLUT16;
	uint8_t *from = (uint8_t *)data;
	uint32_t *to = gSPITransactionBuffer[gTransactionIndex];
	uint16_t i;

	if (bytes > (SPI_BUFFER_SIZE >> 2))
		bytes = SPI_BUFFER_SIZE >> 2;
	*bitsOut = bytes << 5;		// output bits are quadruple input bits

	for (i = 0; i < bytes; i++) {
		uint16_t pixelA, pixelB;
		uint8_t twoPixels = *from++;

		pixelA = clut16_t[twoPixels >> 4];
		pixelA = (pixelA >> 8) | (pixelA << 8);

		pixelB = clut16_t[twoPixels & 0x0F];
		pixelB = (pixelB >> 8) | (pixelB << 8);
		*to++ = (pixelB << 16) | pixelA;
	}

	return bytes;		// input bytes consumed
}

// N.B. callers assume this funtion is synchronous
void modSPITxRx(modSPIConfiguration config, uint8_t *data, uint16_t count)
{
	esp_err_t ret;
	spi_transaction_t t;

	modSPIActivateConfiguration(config);

	memset(&t, 0, sizeof(t));
	t.length = 8 * count;
	t.tx_buffer = data;

	t.rxlength = t.length;
	t.rx_buffer = data;
	ret = spi_device_transmit(config->spi_dev, &t);

	if (0 > ret)
		modLog("problems sending spi message");
}

void modSPIFlush(void)
{
	while (true) {
		xSemaphoreTake(gSPIMutex, portMAX_DELAY);
		int active = gTransactionsPending || (gSPIDataCount > 0);
		xSemaphoreGive(gSPIMutex);
		if (!active) break;
        taskYIELD();
	}
}

static void modSPITxCommon(modSPIConfiguration config, uint8_t *data, uint16_t count, modSPIBufferLoader loader)
{
	if (!config->sync && (config == gConfig)) {
		while (true) {
			xSemaphoreTake(gSPIMutex, portMAX_DELAY);
			int active = (kTransactions == gTransactionsPending) || (gSPIDataCount > 0);
			if (!active) break;
			xSemaphoreGive(gSPIMutex);
			taskYIELD();
		}
	}
	else {
		modSPIActivateConfiguration(config);
		xSemaphoreTake(gSPIMutex, portMAX_DELAY);
	}

	gSPIBufferLoader = loader;
    gSPIData = data;
    gSPIDataCount = count;

    if (config->sync) {
        queueTransfer(config);
		xSemaphoreGive(gSPIMutex);
		modSPIFlush();
    }
	else {
		xSemaphoreGive(gSPIMutex);
		xTaskNotify(gSPITask, (uintptr_t)config, eSetValueWithOverwrite);
	}
}

void modSPITx(modSPIConfiguration config, uint8_t *data, uint16_t count)
{
	modSPITxCommon(config, data, count, modSpiLoadBufferAsIs);
}

void modSPITxSwap16(modSPIConfiguration config, uint8_t *data, uint16_t count)
{
	modSPITxCommon(config, data, count, modSpiLoadBufferSwap16);
}

void modSPITxRGB565LEtoRGB444(modSPIConfiguration config, uint8_t *data, uint16_t count)
{
	modSPITxCommon(config, data, count, modSpiLoadBufferRGB565LEtoRGB444);
}

void modSPITxRGB332To16BE(modSPIConfiguration config, uint8_t *data, uint16_t count)
{
	modSPITxCommon(config, data, count, modSpiLoadBufferRGB332To16BE);
}

void modSPITxGray256To16BE(modSPIConfiguration config, uint8_t *data, uint16_t count)
{
	modSPITxCommon(config, data, count, modSpiLoadBufferGray256To16BE);
}

void modSPITxGray16To16BE(modSPIConfiguration config, uint8_t *data, uint16_t count)
{
	modSPITxCommon(config, data, count, modSpiLoadBufferGray16To16BE);
}

void modSPITxCLUT16To16BE(modSPIConfiguration config, uint8_t *data, uint16_t count, uint16_t *colors)
{
	gCLUT16 = colors;
	modSPITxCommon(config, data, count, modSpiLoadBufferCLUT16To16BE);
}


umber is 0 (no symbols available) or > 0.
	fmt.Fprintf(&buf, "num_symbols: 1\n")

	var b *bufio.Reader
	if r.Method == "POST" {
		b = bufio.NewReader(r.Body)
	} else {
		b = bufio.NewReader(strings.NewReader(r.URL.RawQuery))
	}

	for {
		word, err := b.ReadSlice('+')
		if err == nil {
			word = word[0 : len(word)-1] // trim +
		}
		pc, _ := strconv.ParseUint(string(word), 0, 64)
		if pc != 0 {
			f := runtime.FuncForPC(uintptr(pc))
			if f != nil {
				fmt.Fprintf(&buf, "%#x %s\n", pc, f.Name())
			}
		}

		// Wait until here to check for err; the last
		// symbol will have an err because it doesn't end in +.
		if err != nil {
			if err != io.EOF {
				fmt.Fprintf(&buf, "reading request: %v\n", err)
			}
			break
		}
	}

	w.Write(buf.Bytes())
}

// Handler returns an HTTP handler that serves the named profile.
func Handler(name string) http.Handler {
	return handler(name)
}

type handler string

func (name handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
	w.Header().Set("Content-Type", "text/plain; charset=utf-8")
	debug, _ := strconv.Atoi(r.FormValue("debug"))
	p := pprof.Lookup(string(name))
	if p == nil {
		w.WriteHeader(404)
		fmt.Fprintf(w, "Unknown profile: %s\n", name)
		return
	}
	gc, _ := strconv.Atoi(r.FormValue("gc"))
	if name == "heap" && gc > 0 {
		runtime.GC()
	}
	p.WriteTo(w, debug)
	return
}

// Index responds with the pprof-formatted profile named by the request.
// For example, "/debug/pprof/heap" serves the "heap" profile.
// Index responds to a request for "/debug/pprof/" with an HTML page
// listing the available profiles.
func Index(w http.ResponseWriter, r *http.Request) {
	if strings.HasPrefix(r.URL.Path, "/debug/pprof/") {
		name := strings.TrimPrefix(r.URL.Path, "/debug/pprof/")
		if name != "" {
			handler(name).ServeHTTP(w, r)
			return
		}
	}

	profiles := pprof.Profiles()
	if err := indexTmpl.Execute(w, profiles); err != nil {
		log.Print(err)
	}
}

var indexTmpl = template.Must(template.New("index").Parse(`

<title>/debug/pprof/</title>

/debug/pprof/

profiles:

{{range .}}

{{.Count}}{{.Name}}
{{end}}

full goroutine stack dump

`))
// Copyright 2012 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package cookiejar

// This file implements the Punycode algorithm from RFC 3492.

import (
	"fmt"
	"strings"
	"unicode/utf8"
)

// These parameter values are specified in section 5.
//
// All computation is done with int32s, so that overflow behavior is identical
// regardless of whether int is 32-bit or 64-bit.
const (
	base        int32 = 36
	damp        int32 = 700
	initialBias int32 = 72
	initialN    int32 = 128
	skew        int32 = 38
	tmax        int32 = 26
	tmin        int32 = 1
)

// encode encodes a string


nger_number = 0;
	},
	commander_klon = {
		unique_name = "commander_klon",
		name = "commander",
		desc = "COMMANDER KLON",
		synonyms = { "klon" },
		location = "transporter_room",
		related_object = {"on", "transporter_room_floor" },
		portable = true,
		examine = "Commander Klon is unconscious, but alive.",
		surface = true,
		container_restrictions = { "transporter_tag", "card" },
		passenger_number = 2;
	},
	doctor_nork = {
		unique_name = "doctor_nork",
		name = "doctor",
		desc = "DOCTOR NORK",
		synonyms = { "nork" },
		location = "torpedo_bay",
		related_object = {"on", "torpedo_bay_floor" },
		portable = true,
		examine = "Doctor Nork is unconscious, but alive.",
		surface = true,
		container_restrictions = { "transporter_tag", "card" },
		passenger_number = 3;
	},
	bridge_floor = {
		unique_name = "bridge_floor",
		name = "floor",
		desc = "floor",
		synonyms = { "ground" },
		location = "bridge",
		suppress_itemizing = true,
		portable = false,
		surface = true,
	},
	transporter_tag = {
		unique_name = "transporter_tag",
		name = "tag",
		desc = "a transporter tag",
		synonyms = { "transporter" },
		portable = true,
		location = "pocket",
		related_object = nil,
	},
	eng_door1 = {
		unique_name = "eng_door1",
		name = "door",
		desc = "door to engineering",
		synonyms = { "engineering" },
		portable = false,
		location = "corridor1",
		examine = "The door appears to be locked from the other side",
		suppress_itemizing = true,
		no_open_from_this_side = true,
                doorstatus = "closed",
                doorroom = "engineering",
                doordirout = "aft",
                complement_door = "eng_door2",
	},
	eng_door2 = {
		unique_name = "eng_door2",
		name = "door",
		desc = "door",
		portable = false,
		location = "engineering",
		examine = "The door is a sturdy metal door set in the bulkhead",
		suppress_itemizing = true,
                doorstatus = "closed",
                doorroom = "corridor1",
                doordirout = "fore",
                complement_door = "eng_door1",
	},
	eng_bulkhead = {
		unique_name = "eng_bulkhead",
		name = "bulkhead",
		desc = "a bulkhead",
		location = "corridor1",
		portable = false,
		suppress_itemizing = true,
	},
	eng_bulkhead2 = {
		unique_name = "eng_bulkhead2",
		name = "bulkhead",
		desc = "a bulkhead",
		location = "engineering",
		portable = false,
		suppress_itemizing = true,
	},
	large_fan = {
		unique_name = "large_fan",
		name = "fan",
		desc = "a large, slowly spinning fan.",
		location = "duct3",
		portable = false,
	},
	engineer_bob = {
		unique_name = "engineer_bob",
		name = "engineer",
		desc = "ENGINEER ROBERT BOBBERSON",
		synonyms = { "engineer", "robert", "bob", "bobberson" },
		location = "engineering",
		portable


vector.path
import androidx.compose.ui.unit.dp
import com.woowla.compose.icon.collections.fontawesome.fontawesome.BrandsGroup

public val BrandsGroup.SquareSnapchat: ImageVector
    get() {
        if (_squareSnapchat != null) {
            return _squareSnapchat!!
        }
        _squareSnapchat = Builder(name = "SquareSnapchat", defaultWidth = 448.0.dp, defaultHeight =
                512.0.dp, viewportWidth = 448.0f, viewportHeight = 512.0f).apply {
            path(fill = SolidColor(Color(0xFF000000)), stroke = null, strokeLineWidth = 0.0f,
                    strokeLineCap = Butt, strokeLineJoin = Miter, strokeLineMiter = 4.0f,
                    pathFillType = NonZero) {
                moveTo(384.0f, 32.0f)
                lineTo(64.0f, 32.0f)
                arcTo(64.0f, 64.0f, 0.0f, false, false, 0.0f, 96.0f)
                lineTo(0.0f, 416.0f)
                arcToRelative(64.0f, 64.0f, 0.0f, false, false, 64.0f, 64.0f)
                lineTo(384.0f, 480.0f)
                arcToRelative(64.0f, 64.0f, 0.0f, false, false, 64.0f, -64.0f)
                lineTo(448.0f, 96.0f)
                arcTo(64.0f, 64.0f, 0.0f, false, false, 384.0f, 32.0f)
                close()
                moveTo(380.09f, 351.31f)
                lineTo(380.01f, 351.41f)
                arcToRelative(32.36f, 32.36f, 0.0f, false, true, -8.72f, 6.82f)
                arcToRelative(90.26f, 90.26f, 0.0f, false, true, -20.59f, 8.2f)
                arcToRelative(12.69f, 12.69f, 0.0f, false, false, -3.85f, 1.76f)
                curveToRelative(-2.16f, 1.91f, -2.1f, 4.64f, -4.4f, 8.55f)
                arcToRelative(23.14f, 23.14f, 0.0f, false, true, -6.84f, 7.47f)
                curveToRelative(-6.71f, 4.63f, -14.24f, 4.92f, -22.23f, 5.23f)
                curveToRelative(-7.21f, 0.27f, -15.39f, 0.58f, -24.73f, 3.67f)
                curveToRelative(-3.76f, 1.25f, -7.75f, 3.69f, -12.38f, 6.53f)
                curveToRelative(-11.27f, 6.9f, -26.68f, 16.35f, -52.3f, 16.35f)
                reflectiveCurveToRelative(-40.92f, -9.4f, -52.11f, -16.28f)
                curveToRelative(-4.66f, -2.89f, -8.68f, -5.36f, -12.54f, -6.64f)
                curveToRelative(-9.34f, -3.08f, -17.52f, -3.4f, -24.73f, -3.67f)
                curveToRelative(-7.99f, -0.31f,


_json::Value>,
    #[doc = "The parameters for updating the properties of a webhook."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<WebhookPropertiesUpdateParameters>,
}
impl WebhookUpdateParameters {
    pub fn new() -> Self {
        Self::default()
    }
}
use proconio::input;

fn main() {
    input! {
        n: i64,
        a: [i64; n],
    }

    let mut ans = 0;
    let mut previous = a[0];
    for &i in &a{
        if previous > i{
            ans += previous - i;
        }
        previous = previous.max(i);
    }

    println!("{}", ans);
}
<gh_stars>0
/*
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under both the MIT license found in the
 * LICENSE-MIT file in the root directory of this source tree and the Apache
 * License, Version 2.0 found in the LICENSE-APACHE file in the root directory
 * of this source tree.
 */

use std::io::{self, BufReader, Cursor, Read, Write};

use assert_matches::assert_matches;
use futures::{Async, Poll};
use futures03::compat::Future01CompatExt;
use quickcheck::{quickcheck, Arbitrary, Gen, TestResult};
use tokio_io::io::read_to_end;
use tokio_io::AsyncWrite;

use crate::retry::retry_write;

use crate::compressor::{Compressor, CompressorType};
use crate::decompressor::Decompressor;
use crate::membuf::MemBuf;
use crate::metered::{MeteredRead, MeteredWrite};

quickcheck! {
    fn test_bzip2_roundtrip(cmprs: BzipCompression, input: Vec<u8>) -> TestResult {
        roundtrip(CompressorType::Bzip2(cmprs.0), &input)
    }

    fn test_gzip_roundtrip(cmprs: GzipCompression, input: Vec<u8>) -> TestResult {
        roundtrip(CompressorType::Gzip(cmprs.0), &input)
    }

    fn test_zstd_roundtrip(input: Vec<u8>) -> TestResult {
        roundtrip(CompressorType::Zstd { level: 0 }, &input)
    }

    fn test_bzip_overreading(
        cmprs: BzipCompression,
        compressable_input: Vec<u8>,
        extra_input: Vec<u8>
    ) -> TestResult {
        check_overreading(
            CompressorType::Bzip2(cmprs.0),
            compressable_input.as_slice(),
            extra_input.as_slice(),
        )
    }

    fn test_gzip_overreading(
        cmprs: GzipCompression,
        compressable_input: Vec<u8>,
        extra_input: Vec<u8>
    ) -> TestResult {
        check_overreading(
            CompressorType::Gzip(cmprs.0),
            compressable_input.as_slice(),
            extra_input.as_slice(),
        )
    }
}

#[derive(Debug, Clone)]
struct BzipCompression(bzip2::Compression);
impl Arbitrary for BzipCompression {
    fn arbitrary(g: &mut Gen) -> Self {
        BzipCompression(
            g.choose(&[
                bzip2::Compression::Fastest,
                bzip2::Compression::Best,
                bzip2::Compression::Default,
            ])
            .unwrap()
            .clone(),
        )
    }
}

#[derive(Debug, Clone)]
struct GzipCompression(flate2::Compression);
impl Arbitrary for GzipCompression {
    fn arbitrary(g: &mut Gen) -> Self {
        GzipCompression(
            g.choose(&[
                flate2::Compression::no


t;
	int s;

	sc = device_lookup_private(&bpp_cd, BPPUNIT(dev));

	switch (kn->kn_filter) {
	case EVFILT_READ:
		klist = &sc->sc_rsel.sel_klist;
		kn->kn_fop = &bppread_filtops;
		break;

	case EVFILT_WRITE:
		klist = &sc->sc_wsel.sel_klist;
		kn->kn_fop = &bppwrite_filtops;
		break;

	default:
		return EINVAL;
	}

	kn->kn_hook = sc;

	s = splbpp();
	SLIST_INSERT_HEAD(klist, kn, kn_selnext);
	splx(s);

	return 0;
}

int
bppintr(void *arg)
{
	struct bpp_softc *sc = arg;
	struct lsi64854_softc *lsi = &sc->sc_lsi64854;
	uint16_t irq;

	/* First handle any possible DMA interrupts */
	if (lsi64854_pp_intr((void *)lsi) == -1)
		sc->sc_error = 1;

	irq = bus_space_read_2(lsi->sc_bustag, lsi->sc_regs, L64854_REG_ICR);
	/* Ack all interrupts */
	bus_space_write_2(lsi->sc_bustag, lsi->sc_regs, L64854_REG_ICR,
	    irq | BPP_ALLIRQ);

	DPRINTF(("%s: %x\n", __func__, irq));
	/* Did our device interrupt? */
	if ((irq & BPP_ALLIRQ) == 0)
		return 0;

	if ((sc->sc_flags & BPP_LOCKED) != 0)
		wakeup(sc);
	else if ((sc->sc_flags & BPP_WANT) != 0) {
		sc->sc_flags &= ~BPP_WANT;
		wakeup(sc->sc_buf);
	} else {
		selnotify(&sc->sc_wsel, 0, 0);
		if (sc->sc_asyncproc != NULL)
			softint_schedule(sc->sc_sih);
	}
	return 1;
}

static void
bppsoftintr(void *cookie)
{
	struct bpp_softc *sc = cookie;

	mutex_enter(proc_lock);
	if (sc->sc_asyncproc)
		psignal(sc->sc_asyncproc, SIGIO);
	mutex_exit(proc_lock);
}


2fad]{width:100%;padding:1rem 0;font-size:1.2em;color:#333;font-weight:200;text-align:center}.files[data-v-41d38675]{width:100%;display:grid;grid-gap:15px 15px;grid-template-columns:repeat(auto-fill,minmax(120px,1fr))}.files.model[data-v-41d38675] .file{height:130px;text-align:center;border:none;position:relative;cursor:pointer}.files.model[data-v-41d38675] .file[checkbox=true] .file-checkbox,.files.model[data-v-41d38675] .file:hover .file-checkbox{display:block}.files.model[data-v-41d38675] .file .file-container{width:100%;height:100%;display:flex;flex-wrap:wrap;align-items:center;justify-content:center}.files.model[data-v-41d38675] .file .file-checkbox{position:absolute;top:5px;left:5px;display:none}.files.model[data-v-41d38675] .file .file-date,.files.model[data-v-41d38675] .file .file-type,.files.model[data-v-41d38675] .file .file-size{display:none}.files.model[data-v-41d38675] .file .file-info{width:100%}.files.model[data-v-41d38675] .file .file-info .thumbnail{width:72px;height:72px;margin:0 auto}.files.model[data-v-41d38675] .file .file-info .file-name{width:100%;height:30px;line-height:30px;position:relative;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;text-align:center;padding:0 .5rem;color:var(--text-color);font-size:12px}.files.list[data-v-41d38675]{display:block}.files.list[data-v-41d38675] .file{position:relative;width:100%;height:44px;line-height:44px;padding:0;border-bottom:1px solid #f2f6fd;white-space:nowrap;text-overflow:ellipsis;display:flex;flex-wrap:wrap;align-items:center;margin:2px 0;cursor:pointer}.files.list[data-v-41d38675] .file .file-container{width:100%;height:100%;display:flex;flex-wrap:wrap;align-items:center}.files.list[data-v-41d38675] .file .file-checkbox{display:flex;align-items:center}.files.list[data-v-41d38675] .file .file-checkbox input[type=checkbox]{background:transparent;flex-shrink:0;height:1.25em;width:1.25em;border:2px solid #c9c9c9!important;border-radius:50%!important;transition:all .3s!important;margin:0}.files.list[data-v-41d38675] .file .file-info{max-width:60%;flex:0 0 100%;height:100%;display:flex;overflow:hidden;padding-left:10px;align-items:center}.files.list[data-v-41d38675] .file .file-info .thumbnail{flex:0 0 26px;height:26px;width:26px;display:flex;margin:0;margin-right:.5rem}.files.list[data-v-41d38675] .file .file-info .file-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--text-color);font-size:12px}.files.list[data-v-41d38675] .file .file-date{max-width:15%;flex:0 0 100%;height:100%;display:flex;overfl


import logging
import os
import sys

logger = logging.getLogger("aioredis")
sentinel_logger = logger.getChild("sentinel")

if os.environ.get("AIOREDIS_DEBUG"):
    logger.setLevel(logging.DEBUG)
    handler = logging.StreamHandler(stream=sys.stderr)
    handler.setFormatter(
        logging.Formatter("%(asctime)s %(name)s %(levelname)s %(message)s")
    )
    logger.addHandler(handler)
    os.environ["AIOREDIS_DEBUG"] = ""


/***************************************************************************
 *  projection.h - Laser data projection filter
 *
 *  Created: Tue Mar 22 16:30:51 2011
 *  Copyright  2011  Christoph Schwering
 *
 ****************************************************************************/

/*  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU Library General Public License for more details.
 *
 *  Read the full text in the LICENSE.GPL file in the doc directory.
 */

#ifndef _PLUGINS_LASER_FILTER_FILTERS_PROJECTION_H_
#define _PLUGINS_LASER_FILTER_FILTERS_PROJECTION_H_

#include "filter.h"

#ifndef HAVE_TF
#	error LaserProjectionDataFilter only availabe with TF
#endif

#include <tf/transformer.h>

#include <string>

namespace fawkes {
class Configuration;
class Logger;
} // namespace fawkes

class LaserProjectionDataFilter : public LaserDataFilter
{
public:
	LaserProjectionDataFilter(const std::string                      &filter_name,
	                          fawkes::tf::Transformer                *tf,
	                          std::string                             target_frame,
	                          float                                   not_from_x,
	                          float                                   not_to_x,
	                          float                                   not_from_y,
	                          float                                   not_to_y,
	                          float                                   only_from_z,
	                          float                                   only_to_z,
	                          unsigned int                            in_data_size,
	                          std::vector<LaserDataFilter::Buffer *> &in);
	~LaserProjectionDataFilter();

	void filter();

private:
	inline void set_output(float *outbuf, fawkes::tf::Point &p);

private:
	fawkes::tf::Transformer *tf_;
	const std::string        target_frame_;
	const float              not_from_x_, not_to_x_;
	const float              not_from_y_, not_to_y_;
	const float              only_from_z_, only_to_z_;

	float sin_angles360[360];
	float cos_angles360[360];
	float sin_angles720[720];
	float cos_angles720[720];

	float index_factor_;
};

#endif


())
		{
			final String aString = aTok.nextToken();
			list.add(aString);
		}
		gameMode.setMonsterRoleList(list);
		return true;
	}
}
/*
 * ActypeToken.java
 * Copyright 2005 (C) Greg Bingleman <byngl@hotmail.com>
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 */
package plugin.lsttokens.gamemode;

import java.net.URI;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import java.util.StringTokenizer;

import pcgen.cdom.base.Constants;
import pcgen.cdom.content.ACControl;
import pcgen.core.GameMode;
import pcgen.core.prereq.Prerequisite;
import pcgen.persistence.PersistenceLayerException;
import pcgen.persistence.lst.GameModeLstToken;
import pcgen.persistence.lst.prereq.PreParserFactory;
import pcgen.util.Logging;

/**
 * {@code ActypeToken}
 *
 */
public class ActypeToken implements GameModeLstToken
{

	@Override
	public String getTokenName()
	{
		return "ACTYPE";
	}

	@Override
	public boolean parse(GameMode gameMode, String value, URI source)
	{
		final StringTokenizer aTok = new StringTokenizer(value, "\t");

		if (!aTok.hasMoreTokens())
		{
			Logging.errorPrint("Empty tag in miscinfo.ACTYPE");

			return false;
		}

		final String acType = aTok.nextToken();

		while (aTok.hasMoreTokens())
		{
			final String aString = aTok.nextToken();

			if (aString.startsWith("ADD:"))
			{
				Collection<ACControl> controls = parseACControl(aString.substring(4));
				if (controls == null)
				{
					return false;
				}
				gameMode.addACAdds(acType, controls);
			}
			else if (aString.startsWith("REMOVE:"))
			{
				Collection<ACControl> controls = parseACControl(aString.substring(7));
				if (controls == null)
				{
					return false;
				}
				gameMode.addACRemoves(acType, controls);
			}
			else
			{
				Logging.errorPrint("Incorrect tag in miscinfo.ACTYPE: " + aString);
				return false;
			}
		}
		return true;
	}

	private Collection<ACControl> parseACControl(String str)
	{
		StringTokenizer st = new StringTokenizer(str, Constants.PIPE);
		List<ACControl> acTypes = new ArrayList<>();
		String token;
		while (true)
		{
			token = st.nextToken();
			if (PreParserFactory.isPreReqString(token))
			{
				break;
			}
			acTypes.add(new ACControl(token));
			if (!st.hasMoreTokens())
			{
				return acTypes;
			}
		}
		if (acTypes.isEmpty())
		{
			Logging.errorPrint("No types found in actype control: " + str);
			return null;
		}
		while (true)
		{
			try
			{
				PreParserFactory factory = PreParserFactory.getInstance();
				Prerequisite prereq = factory.parse(token);
				for (ACControl ac


		[1508] = {
				[1384] = 86,
				[1440] = 116,
				[1447] = 121,
				[1452] = 80,
				[1467] = 89,
				[1476] = 94,
				[1493] = 23,
				[1502] = 133,
				[1509] = 32,
				[1510] = 41,
				[1513] = 37,
				[1515] = 43,
				[1568] = 221,
				[1569] = 55,
				[1572] = 172,
				[1573] = 135,
				[1580] = 242,
				[1643] = 152,
				["name"] = "Veil Terokk",
			},
			[1515] = {
				[1448] = 81,
				[1450] = 80,
				[1462] = 55,
				[1467] = 84,
				[1476] = 74,
				[1493] = 37,
				[1503] = 147,
				[1508] = 18,
				[1509] = 26,
				[1510] = 43,
				[1511] = 152,
				[1513] = 41,
				[1528] = 145,
				[1569] = 49,
				[1647] = 129,
				["name"] = "Crow's Crook",
			},
			[1513] = {
				[1440] = 103,
				[1450] = 63,
				[1452] = 52,
				[1453] = 39,
				[1476] = 78,
				[1493] = 40,
				[1508] = 29,
				[1510] = 58,
				[1515] = 24,
				[1539] = 174,
				[1568] = 187,
				[1569] = 45,
				[1572] = 159,
				[1643] = 138,
				["name"] = "Apexis Excavation",
			},
			-- Shadowmoon Valley
			[1476] = {
				[1381] = 41,
				[1382] = 45,
				[1383] = 63,
				[1384] = 39,
				[1389] = 168,
				[1420] = 109,
				[1440] = 69,
				[1447] = 67,
				[1448] = 77,
				[1450] = 71,
				[1451] = 31,
				[1452] = 98,
				[1453] = 73,
				[1462] = 44,
				[1467] = 66,
				[1468] = 62,
				[1475] = 71,
				[1493] = 99,
				[1502] = 123,
				[1503] = 148,
				[1506] = 130,
				[1507] = 151,
				[1508] = 70,
				[1509] = 67,
				[1510] = 97,
				[1511] = 79,
				[1513] = 91,
				[1515] = 64,
				[1518] = 136,
				[1519] = 153,
				[1520] = 127,
				[1523] = 103,
				[1524] = 170,
				[1528] = 110,
				[1529] = 81,
				[1539] = 148,
				[1556] = 82,
				[1568] = 134,
				[1569] = 38,
				[1572] = 176,
				[1573] = 149,
				[1574] = 155,
				[1580] = 163,
				[1620] = 73,
				[1643] = 98,
				[1645] = 85,
				[1646] = 60,
				[1647] = 74,
				[1648] = 89,
				["name"] = "Lunarfall (Alliance)",
			},
			[1384] = {
				[1381] = 21,
				[1382] = 34,
				[1383] = 41,
				[1420


hover,.cc-banner .cc-link:focus{text-decoration:underline}.cc-banner .cc-link:focus{outline:0;background:#dae6ef;background:content-box rgba(0,120,215,.1)}@keyframes fadeIn{from{opacity:0}to{opacity:1}}@-o-keyframes fadeIn{from{opacity:0;}to{opacity:1;}}@-moz-keyframes fadeIn{from{opacity:0}to{opacity:1}}@-webkit-keyframes fadeIn{from{opacity:0}to{opacity:1}}div.links a{margin-left:16px;margin-right:16px}div.links a.first{padding-left:0}body.cb{color:#262626;text-align:left}.fadeIn{-webkit-animation:fadeIn 1s;-moz-animation:fadeIn 1s;-o-animation:fadeIn 1s;animation:fadeIn 1s}.backgroundImage{-webkit-animation:fadeIn 1s;-moz-animation:fadeIn 1s;-o-animation:fadeIn 1s;animation:fadeIn 1s}.background-logo{max-width:256px;max-height:36px;display:block;margin-left:auto;margin-right:auto;-webkit-animation:fadeIn 1s;-moz-animation:fadeIn 1s;-o-animation:fadeIn 1s;animation:fadeIn 1s}.background-logo-holder{height:36px;margin-bottom:24px}.background{background:#f2f2f2}.background,.background>div{position:fixed;top:0;width:100%;height:100%}.background>div{background-repeat:no-repeat,no-repeat;background-position:center center,center center;background-size:cover,cover}.background-overlay{background:rgba(0,0,0,.55);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#8C000000',endColorstr='#8C000000');width:100%;height:100%}.footer{position:fixed;bottom:0;width:100%;overflow:visible;z-index:99;clear:both;background-color:rgba(0,0,0,.6);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#99000000',endColorstr='#99000000')}.outer{display:table;position:absolute;height:100%;width:100%}.middle{display:table-cell;vertical-align:middle}.inner{margin-left:auto;margin-right:auto;position:relative;max-width:440px;width:calc(100% - 40px);padding:44px;margin-bottom:28px;background-color:#fff;-webkit-box-shadow:0 2px 3px rgba(0,0,0,.55);-moz-box-shadow:0 2px 3px rgba(0,0,0,.55);box-shadow:0 2px 3px rgba(0,0,0,.55);border:1px solid #818c94;border:1px solid rgba(0,0,0,.4);min-width:320px;min-height:338px}.new-session-popup{margin-left:auto;margin-right:auto;position:relative;max-width:440px;width:calc(100% - 40px);padding:44px;margin-bottom:28px;background-color:#fff;-webkit-box-shadow:0 2px 3px rgba(0,0,0,.55);-moz-box-shadow:0 2px 3px rgba(0,0,0,.55);box-shadow:0 2px 3px rgba(0,0,0,.55);border:1px solid #818c94;border:1px solid rgba(0,0,0,.4);min-width:320px}.new-session-popup .content{line-height:16px}.new-session-popup .content>*{word-wrap:break-word}.new-session-popup .close-button{width:12px}.new-session-popup .table-cell:first-child{width:100%}.alt-cred-hint-holder{position:relative;margin-top:-36px}.action-links .alt-c


import torch
from gsplat import rasterization
from dust3r.utils.geometry import inv, geotrf

def render(
    intrinsics: torch.Tensor,
    pts3d: torch.Tensor,
    rgbs: torch.Tensor | None = None,
    scale: float = 0.002,
    opacity: float = 0.95,
):

    device = pts3d.device
    batch_size = len(intrinsics)
    img_size = pts3d.shape[1:3]
    pts3d = pts3d.reshape(batch_size, -1, 3)
    num_pts = pts3d.shape[1]
    quats = torch.randn((num_pts, 4), device=device)
    quats = quats / quats.norm(dim=-1, keepdim=True)
    scales = scale * torch.ones((num_pts, 3), device=device)
    opacities = opacity * torch.ones((num_pts), device=device)
    if rgbs is not None:
        assert rgbs.shape[1] == 3
        rgbs = rgbs.reshape(batch_size, 3, -1).transpose(1, 2)
    else:
        rgbs = torch.ones_like(pts3d[:, :, :3])

    rendered_rgbs = []
    rendered_depths = []
    accs = []
    for i in range(batch_size):
        rgbd, acc, _ = rasterization(
            pts3d[i],
            quats,
            scales,
            opacities,
            rgbs[i],
            torch.eye(4, device=device)[None],
            intrinsics[[i]],
            width=img_size[1],
            height=img_size[0],
            packed=False,
            render_mode="RGB+D",
        )

        rendered_depths.append(rgbd[..., 3])

    rendered_depths = torch.cat(rendered_depths, dim=0)

    return rendered_rgbs, rendered_depths, accs

def get_render_results(gts, preds, self_view=False):
    device = preds[0]["pts3d_in_self_view"].device
    with torch.no_grad():
        depths = []
        gt_depths = []
        for i, (gt, pred) in enumerate(zip(gts, preds)):
            if self_view:
                camera = inv(gt["camera_pose"]).to(device)
                intrinsics = gt["camera_intrinsics"].to(device)
                pred = pred["pts3d_in_self_view"]
            else:
                camera = inv(gts[0]["camera_pose"]).to(device)
                intrinsics = gts[0]["camera_intrinsics"].to(device)
                pred = pred["pts3d_in_other_view"]
            gt_img = gt["img"].to(device)
            gt_pts3d = gt["pts3d"].to(device)

            _, depth, _ = render(intrinsics, pred, gt_img)
            _, gt_depth, _ = render(intrinsics, geotrf(camera, gt_pts3d), gt_img)
            depths.append(depth)
            gt_depths.append(gt_depth)
    return depths, gt_depths


Over="ShowTip(event, 'tt620', 'link621')" onMouseOut="HideTip('tt620')" class=IParent>uvm_memuvm_reguvm_reg_block

 	get_current_item
uvm_sequence#(REQ,RSP)uvm_sequencer_param_base#(REQ,RSP)

 	get_data
uvm_tlm_generic_payload

 	get_data_length
uvm_tlm_generic_payload

 	get_db
uvm_tr_stream

 	get_default_hdl_path
uvm_reg_blockuvm_reg


/*
 *      ANSI C implementation of vector operations.
 *
 * Copyright (c) 2007-2010 Naoaki Okazaki
 * All rights reserved.
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 */

/* $Id$ */

#include <stdlib.h>
#include <memory.h>

#if     LBFGS_FLOAT == 32 && LBFGS_IEEE_FLOAT
#define fsigndiff(x, y) (((*(uint32_t*)(x)) ^ (*(uint32_t*)(y))) & 0x80000000U)
#else
#define fsigndiff(x, y) (*(x) * (*(y) / fabs(*(y))) < 0.)
#endif/*LBFGS_IEEE_FLOAT*/

inline static void* vecalloc(size_t size)
{
    void *memblock = malloc(size);
    if (memblock) {
        memset(memblock, 0, size);
    }
    return memblock;
}

inline static void vecfree(void *memblock)
{
    free(memblock);
}

inline static void vecset(lbfgsfloatval_t *x, const lbfgsfloatval_t c, const int n)
{
    int i;

    for (i = 0;i < n;++i) {
        x[i] = c;
    }
}

inline static void veccpy(lbfgsfloatval_t *y, const lbfgsfloatval_t *x, const int n)
{
    int i;

    for (i = 0;i < n;++i) {
        y[i] = x[i];
    }
}

inline static void vecncpy(lbfgsfloatval_t *y, const lbfgsfloatval_t *x, const int n)
{
    int i;

    for (i = 0;i < n;++i) {
        y[i] = -x[i];
    }
}

inline static void vecadd(lbfgsfloatval_t *y, const lbfgsfloatval_t *x, const lbfgsfloatval_t c, const int n)
{
    int i;

    for (i = 0;i < n;++i) {
        y[i] += c * x[i];
    }
}

inline static void vecdiff(lbfgsfloatval_t *z, const lbfgsfloatval_t *x, const lbfgsfloatval_t *y, const int n)
{
    int i;

    for (i = 0;i < n;++i) {
        z[i] = x[i] - y[i];
    }
}

inline static void vecscale(lbfgsfloatval_t *y, const lbfgsfloatval_t c, const int n)
{
    int i;

    for (i = 0;i < n;++i) {
        y[i] *= c;
    }
}

inline static void vecmul(lbfgsfloatval_t *y, const lbfgsfloatval_t *x, const int n)
{
    int i;

    for (i = 0;i < n;++i) {
        y[i] *= x[i];
    }
}

inline static void vecdot(lbfgsfloatval_t* s, const lbfgsfloatval_t *x, const lbfgsfloatval_t *y, const int n)
{
    int i;
    *s = 0.;
    for (i = 0;i < n;++i) {
        *s += x[i] * y[i];
    }
}

inline static void vec2norm(lbfgsfloatval_t* s, const lbfgsfloatval_t *x, const int n)
{
    vecdot(s, x, x, n);
    *s = (lbfgsfloatval_t)sqrt(*s);
}

inline static void vec2norminv(lbfgsfloatval_t* s, const lbfgsfloatval_t *x, const int n)
{
    vec2norm(s, x, n);
    *s = (lbfgsfloatval_t)(1.0 / *s);
}


d %d",&n,&x);
	gph[x].push_back(n+1);
	gph[n+1].push_back(x);
	c[n+1] = 2e15;
	for(int i=1; i<=n; i++){
		scanf("%lld",&c[i]);
	}
	for(int i=0; i<n-1; i++){
		int s, e;
		scanf("%d %d",&s,&e);
		gph[s].push_back(e);
		gph[e].push_back(s);
	}
	auto ret = dfs(1, 0);
	lint curhel = 0;
	while(!ret.empty()){
		auto t = ret.top();
		ret.pop();
		if(curhel < t.first) break;
		curhel += t.second - t.first;
	}
	if(curhel > 1e15) puts("escaped");
	else puts("trapped");
}

int main(){
	int t;
	cin >>t;
	while(t--){
		solve();
		for(int i=1; i<=n+1; i++){
			gph[i].clear();
		}
	}
}
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <limits.h>
#include <stack>
#include <queue>
#include <map>
#include <set>
#include <algorithm>
#include <string>
#include <functional>
#include <vector>
#include <numeric>
#include <deque>
#include <bitset>
#include <iostream>
using namespace std;
typedef long long lint;
typedef long double llf;
typedef pair<int, int> pi;
const int MAXC = 20000;

int n;
vector<int> vx[20005], vy[20005];
pi a[1005];

int ccw(pi a, pi b, pi c){
	int dx1 = b.first - a.first;
	int dy1 = b.second - a.second;
	int dx2 = c.first - a.first;
	int dy2 = c.second - a.second;
	return dx1 * dy2 - dy1 * dx2;
}

char move(int dx, int dy){
	if(dy < 0) return 'S';
	if(dy > 0) return 'N';
	if(dx < 0) return 'W';
	return 'E';
}

void solve(){
	for(int i=0; i<=MAXC; i++){
		vx[i].clear();
		vy[i].clear();
	}
	cin >> n;
	if(n == 0) exit(0);
	for(int i=0; i<n; i++){
		cin >> a[i].first >> a[i].second;
		a[i].first += MAXC / 2;
		a[i].second += MAXC / 2;
		vx[a[i].first].push_back(a[i].second);
		vy[a[i].second].push_back(a[i].first);
	}
	for(int i=0; i<=MAXC; i++){
		sort(vx[i].begin(), vx[i].end());
		sort(vy[i].begin(), vy[i].end());
	}
	vector<pi> ord;
	int px = a[0].first, py = a[0].second;
	int l = 0;
	for(int i=0; i<n; i++){
		ord.push_back(pi(px, py));
		if(l == 0){
			int cntx = lower_bound(vx[px].begin(), vx[px].end(), py) - vx[px].begin();
			py = vx[px][cntx^1];
		}
		else{
			int c


<ompts:test>
<ompts:testdescription>Test with omp for collapse clause. Bind with two loops. Without the collapse clause, the first loop will not be ordered</ompts:testdescription>
<ompts:ompversion>3.0</ompts:ompversion>
<ompts:directive>omp for collapse</ompts:directive>
<ompts:dependences>omp critical,omp for schedule</ompts:dependences>
<ompts:testcode>
#include <stdio.h>
#include <math.h>

#include "omp_testsuite.h"

/* Utility function to check that i is increasing monotonically
   with each call */
static int check_i_islarger (int i)
{
    static int last_i;
    int islarger;
    if (i==1)
      last_i=0;
    islarger = ((i >= last_i)&&(i - last_i<=1));
    last_i = i;
    return (islarger);
}

int <ompts:testcode:functionname>omp_for_collapse</ompts:testcode:functionname> (FILE * logFile)
{
    <ompts:orphan:vars>
	int is_larger = 1;
    </ompts:orphan:vars>

    #pragma omp parallel
    {
	<ompts:orphan>
	  int i,j;
	  int my_islarger = 1;
      #pragma omp for private(i,j) schedule(static,1) <ompts:check>collapse(2)</ompts:check> ordered
	    for (i = 1; i < 100; i++){
          <ompts:crosscheck>my_islarger = check_i_islarger(i)&& my_islarger;</ompts:crosscheck>
          for (j =1; j <100; j++)
          {
            <ompts:check>
		    #pragma omp ordered
		      my_islarger = check_i_islarger(i)&&my_islarger;
            </ompts:check>
	      }	/* end of for */
        }
      #pragma omp critical
		is_larger = is_larger && my_islarger;
	</ompts:orphan>
    }

    return (is_larger);
}
</ompts:testcode>
</ompts:test>


   PlaylistUri("a:invalid").uri
        }

        assertFailsWith<SpotifyUriException> {
            PlaylistUri("a:invalid").id
        }

        assertFailsWith<SpotifyUriException> {
            PlaylistUri("spotify:track:1Z9UVqWuRJ7zToOiVnlXRO").uri
        }

        assertEquals(
            "spotify:playlist:66wcLiS5R50akaQ3onDyZd",
            PlaylistUri("spotify:playlist:66wcLiS5R50akaQ3onDyZd").uri
        )

        assertEquals(
            "66wcLiS5R50akaQ3onDyZd",
            PlaylistUri("spotify:playlist:66wcLiS5R50akaQ3onDyZd").id
        )

        assertEquals(
            "spotify:playlist:66wcLiS5R50akaQ3onDyZd",
            PlaylistUri("66wcLiS5R50akaQ3onDyZd").uri
        )

        assertEquals(
            "66wcLiS5R50akaQ3onDyZd",
            PlaylistUri("66wcLiS5R50akaQ3onDyZd").id
        )

        assertEquals(
            "spotify:playlist:66wcLiS5R50akaQ3onDyZd",
            PlaylistUri("spotify:user:7r7uq6qxa4ymx3wnjd9mm6i83:playlist:66wcLiS5R50akaQ3onDyZd").uri
        )

        assertEquals(
            "66wcLiS5R50akaQ3onDyZd",
            PlaylistUri("spotify:user:7r7uq6qxa4ymx3wnjd9mm6i83:playlist:66wcLiS5R50akaQ3onDyZd").id
        )
    }

    @Test
    fun testAlbumUri() {
        assertFailsWith<SpotifyUriException> {
            AlbumUri("a:invalid")
        }

        assertFailsWith<SpotifyUriException> {
            AlbumUri("a:invalid").uri
        }

        assertFailsWith<SpotifyUriException> {
            AlbumUri("a:invalid").id
        }

        assertFailsWith<SpotifyUriException> {
            AlbumUri("spotify:user:7r7uq6qxa4ymx3wnjd9mm6i83").uri
        }

        assertEquals(
            "spotify:album:0W0ag2P4h1Fmp7PnGJVvIJ",
            AlbumUri("spotify:album:0W0ag2P4h1Fmp7PnGJVvIJ").uri
        )

        assertEquals(
            "0W0ag2P4h1Fmp7PnGJVvIJ",
            AlbumUri("spotify:album:0W0ag2P4h1Fmp7PnGJVvIJ").id
        )

        assertEquals(
            "spotify:album:0W0ag2P4h1Fmp7PnGJVvIJ",
            AlbumUri("0W0ag2P4h1Fmp7PnGJVvIJ").uri
        )

        assertEquals(
            "0W0ag2P4h1Fmp7PnGJVvIJ",
            AlbumUri("0W0ag2P4h1Fmp7PnGJVvIJ").id
        )
    }

    @Test
    fun testArtistUri() {
        assertFailsWith<SpotifyUriException> {
            ArtistUri("a:invalid")
        }

        assertFailsWith<SpotifyUriException> {
            ArtistUri("a:invalid").uri
        }

        assertFailsWith<SpotifyUriException> {
            ArtistUri("a:invalid").id
        }

        assertFailsWith<SpotifyUriException> {
            ArtistUri("spotify:user:7r7uq6qxa4ymx3wnjd9mm6i83").uri
        }

        assertEquals(
            "spotify:artist:1XLjkBxFokuDTlHt0mQkRe",
            ArtistUri("spotify:artist:1XLjkBxFokuDTlHt0mQ


from django.urls import re_path as url

from corehq.apps.hqwebapp.decorators import waf_allow

from .views import (
    DowngradeLocationsView,
    DownloadLocationStatusView,
    EditLocationView,
    FilteredLocationDownload,
    LocationFieldsView,
    LocationImportStatusView,
    LocationImportView,
    LocationsListView,
    LocationsSearchView,
    LocationTypesView,
    NewLocationView,
    archive_location,
    default,
    delete_location,
    location_descendants_count,
    location_download_job_poll,
    location_export,
    location_importer_job_poll,
    location_lineage,
    unarchive_location,
    unassign_users,
    count_locations,
    bulk_location_upload_api,
)

settings_urls = [
    url(r'^$', default, name='default_locations_view'),
    url(r'^list/$', LocationsListView.as_view(), name=LocationsListView.urlname),
    url(r'^location_search/$', LocationsSearchView.as_view(), name='location_search'),
    url(r'^location_search_has_users_only/$', LocationsSearchView.as_view(
        include_locations_with_no_users=False), name='location_search_has_users_only'),
    url(r'^location_types/$', LocationTypesView.as_view(), name=LocationTypesView.urlname),
    url(r'^import/$', waf_allow('XSS_BODY')(LocationImportView.as_view()), name=LocationImportView.urlname),
    url(r'^import/bulk_location_upload_api/$', bulk_location_upload_api, name='bulk_location_upload_api'),
    url(r'^import_status/(?P<download_id>(?:dl-)?[0-9a-fA-Z]{25,32})/$', LocationImportStatusView.as_view(),
        name=LocationImportStatusView.urlname),
    url(r'^location_importer_job_poll/(?P<download_id>(?:dl-)?[0-9a-fA-Z]{25,32})/$',
        location_importer_job_poll, name='location_importer_job_poll'),
    url(r'^export_locations/$', location_export, name='location_export'),
    url(r'^export_status/(?P<download_id>(?:dl-)?[0-9a-fA-Z]{25,32})/$',
        DownloadLocationStatusView.as_view(), name=DownloadLocationStatusView.urlname),
    url(r'^export_job_poll/(?P<download_id>(?:dl-)?[0-9a-fA-Z]{25,32})/$',
        location_download_job_poll, name='org_download_job_poll'),
    url(r'^count_locations/$', count_locations, name='locations_count'),
    url(r'^filter_and_download/$', FilteredLocationDownload.as_view(),
        name=FilteredLocationDownload.urlname),
    url(r'^new/$', NewLocationView.as_view(), name=NewLocationView.urlname),
    url(r'^fields/$', LocationFieldsView.as_view(), name=LocationFieldsView.urlname),
    url(r'^downgrade/$', DowngradeLocationsView.as_view(),
        name=DowngradeLocationsView.urlname),
    url(r'^unassign_users/$', unassign_users, name='unassign_users'),
    url(r'^(?P<loc_id>[\w-]+)/archive/$', archive_location, name='archive_location'),
    url(r'^(?P<loc_id>[\w-]+)/unarchive/$', unarchive_location, name='unarchive_location'),
    url(r'^(?P<loc_id>[\w-]+)/delete/$', delete_location, name='delete_location'),
    url(r'^(?P<loc_id>[\w-]+)/lineage/$', location_lineage, name='location_lineage'),
    url(r'^(?P<loc_id>[\w-]+)/descendants/$', location_descendants_count, name='location_descendants_count'),
    url(r'^(?P<loc_id>[\w-]+)/$', EditLocationView.as_view(), name=EditLocationView.urlname),
]


MetaObjectFromPointer(unsafe.Pointer(uintptr(rv))) // 444
}

// /usr/include/qt/QtWinExtras/../../src/winextras/qwinthumbnailtoolbar.h:64
// index:0
// Public Visibility=Default Availability=Available
// [-2] void QWinThumbnailToolBar(QObject *)

/*
Constructs a QWinThumbnailToolBar with the specified parent.

If parent is an instance of QWindow, it is automatically assigned as the thumbnail toolbar's window.
*/
func (*QWinThumbnailToolBar) NewForInherit(parent qtcore.QObject_ITF /*777 QObject **/) *QWinThumbnailToolBar {
	return NewQWinThumbnailToolBar(parent)
}
func NewQWinThumbnailToolBar(parent qtcore.QObject_ITF /*777 QObject **/) *QWinThumbnailToolBar {
	var convArg0 unsafe.Pointer
	if parent != nil && parent.QObject_PTR() != nil {
		convArg0 = parent.QObject_PTR().GetCthis()
	}
	rv, err := qtrt.InvokeQtFunc6("_ZN20QWinThumbnailToolBarC2EP7QObject", qtrt.FFI_TYPE_POINTER, convArg0)
	qtrt.ErrPrint(err, rv)
	gothis := NewQWinThumbnailToolBarFromPointer(unsafe.Pointer(uintptr(rv)))
	qtrt.ConnectDestroyed(gothis, "QWinThumbnailToolBar")
	return gothis
}

// /usr/include/qt/QtWinExtras/../../src/winextras/qwinthumbnailtoolbar.h:64
// index:0
// Public Visibility=Default Availability=Available
// [-2] void QWinThumbnailToolBar(QObject *)

/*
Constructs a QWinThumbnailToolBar with the specified parent.

If parent is an instance of QWindow, it is automatically assigned as the thumbnail toolbar's window.
*/
func (*QWinThumbnailToolBar) NewForInheritp() *QWinThumbnailToolBar {
	return NewQWinThumbnailToolBarp()
}
func NewQWinThumbnailToolBarp() *QWinThumbnailToolBar {
	// arg: 0, QObject *=Pointer, QObject=Record, , Invalid
	var convArg0 unsafe.Pointer
	rv, err := qtrt.InvokeQtFunc6("_ZN20QWinThumbnailToolBarC2EP7QObject", qtrt.FFI_TYPE_POINTER, convArg0)
	qtrt.ErrPrint(err, rv)
	gothis := NewQWinThumbnailToolBarFromPointer(unsafe.Pointer(uintptr(rv)))
	qtrt.ConnectDestroyed(gothis, "QWinThumbnailToolBar")
	return gothis
}

// /usr/include/qt/QtWinExtras/../../src/winextras/qwinthumbnailtoolbar.h:65
// index:0
// Public virtual Visibility=Default Availability=Available
// [-2] void ~QWinThumbnailToolBar()

/*

 */
func DeleteQWinThumbnailToolBar(this *QWinThumbnailToolBar) {
	rv, err := qtrt.InvokeQtFunc6("_ZN20QWinThumbnailToolBarD2Ev", qtrt.FFI_TYPE_VOID, this.GetCthis())
	qtrt.Cmemset(this.GetCthis(), 9, 24)
	qtrt.ErrPrint(err, rv)
	this.SetCthis(nil)
}

// /usr/include/qt/QtWinExtras/../../src/winextras/qwinthumbnailtoolbar.h:67
// index:0
// Public Visibility=Default Availability=Available
// [-2] void setWindow(QWindow *)

/*

 */
func (this *QWinThumbnailToolBar) SetWindow(window qtgui.QWindow_ITF /*777 QWindow **/) {
	var convArg0 unsafe.Po


nd)
        {
            super.readStructureFromNBT(tagCompound);
            this.field_111021_b = tagCompound.getBoolean("Chest");
        }

        protected void writeStructureToNBT(NBTTagCompound tagCompound)
        {
            super.writeStructureToNBT(tagCompound);
            tagCompound.setBoolean("Chest", this.field_111021_b);
        }

        public void buildComponent(StructureComponent componentIn, List<StructureComponent> listIn, Random rand)
        {
            this.getNextComponentX((StructureNetherBridgePieces.Start)componentIn, listIn, rand, 0, 1, true);
        }

        public static StructureNetherBridgePieces.Corridor func_175879_a(List<StructureComponent> p_175879_0_, Random p_175879_1_, int p_175879_2_, int p_175879_3_, int p_175879_4_, EnumFacing p_175879_5_, int p_175879_6_)
        {
            StructureBoundingBox structureboundingbox = StructureBoundingBox.getComponentToAddBoundingBox(p_175879_2_, p_175879_3_, p_175879_4_, -1, 0, 0, 5, 7, 5, p_175879_5_);
            return isAboveGround(structureboundingbox) && StructureComponent.findIntersecting(p_175879_0_, structureboundingbox) == null ? new StructureNetherBridgePieces.Corridor(p_175879_6_, p_175879_1_, structureboundingbox, p_175879_5_) : null;
        }

        public boolean addComponentParts(World worldIn, Random randomIn, StructureBoundingBox structureBoundingBoxIn)
        {
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 0, 0, 0, 4, 1, 4, Blocks.nether_brick.getDefaultState(), Blocks.nether_brick.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 0, 2, 0, 4, 5, 4, Blocks.air.getDefaultState(), Blocks.air.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 4, 2, 0, 4, 5, 4, Blocks.nether_brick.getDefaultState(), Blocks.nether_brick.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 4, 3, 1, 4, 4, 1, Blocks.nether_brick_fence.getDefaultState(), Blocks.nether_brick_fence.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 4, 3, 3, 4, 4, 3, Blocks.nether_brick_fence.getDefaultState(), Blocks.nether_brick_fence.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 0, 2, 0, 0, 5, 0, Blocks.nether_brick.getDefaultState(), Blocks.nether_brick.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 0, 2, 4, 3, 5, 4, Blocks.nether_brick.getDefaultState(), Blocks.nether_brick.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 1, 3, 4, 1, 4, 4, Blocks.nether_brick_fence.getDefaultState(), Blocks.nether_brick.getDefaultState(), false);
            this.fillWithBlocks(worldIn, structureBoundingBoxIn, 3, 3, 4, 3, 4, 4, Blocks.nether_brick_fence.getDefaultState(), Bl


fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-bicycle:before{content:"\f206"}.fa-bus:before{content:"\f207"}.fa-ioxhost:before{content:"\f208"}.fa-angellist:before{content:"\f209"}.fa-cc:before{content:"\f20a"}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:"\f20b"}.fa-meanpath:before{content:"\f20c"}body {
  font-family: 'Futura', 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS',
    sans-serif;
  margin: 0;
  background: linear-gradient(#099, #86d);
  background-attachment: fixed;
}

.bpm-meter {
  padding: 11px;
  text-align: center;
}

.bpm-meter__input {
  font-family: 'Futura', 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS';
  border: none;
  padding: 11px;
  margin-left: 11px;
  font-size: 18px;
  color: 13px;
  border-radius: 4px;
  box-shadow: rgba(0, 0, 0, 0.125) 0 4px 1px inset;
  color: #999;
}

.demo {
  margin: 22px;
  border-radius: 8px;
  background: #fafafa;
  box-shadow: rgba(0, 0, 0, 0.125) 8px 8px 0;
  border: 1px solid #eee;
}

h1 {
  font-size: 18px;
  font-weight: normal;
  color: rebeccapurple;
  padding: 11px;
  margin: 0;
  text-transform: uppercase;
  border-bottom: 1px solid #dfdfd0;
}

.instructions {
  padding: 11px;
  margin: 11px;
  color: #777;
  margin: none;
  font-family: monospace;
  background: #f9f9e6;
  border: 1px solid #f0f0de;
}

.instructions kbd {
  background: #ff0;
  display: inline-block;
  padding: 3px;
}

.list {
  list-style-type: none;
  margin: 0;
  padding: 0;
}

.list-item {
  display: block;
  padding: 14px;
  font-size: 16px;
  border-bottom: 1px solid #dfdfd0;
  color: #666;
}

.list-item--selected {
  background: tomato;
  color: gold;
  text-shadow: rgba(0, 0, 0, 0.5) 1px 1px 0;
}

.footer {
  color: #777;
  padding: 11px;
}

.modal {
  background: rgba(0, 0, 0, 0.5);
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.modal__content {
  background: white;
  border-radius: 4px;
  padding: 22px;
  border: 1px solid #aaa;
  box-shadow: rgba(0, 0, 0, 0.2) 4px 4px 0;
}

.modal__content h3 {
  text-align: center;
  font-weight: normal;
  color: #999;
  font-size: 18px;
}

.modal__content h2 {
  text-align: center;
  font-weight: bold;
  color: #555;
  font-size: 22px;
  color: rebeccapurple;
}

.modal__content-help {
  padding: 11px


�വേശിപ്പിക്കുന്നതാണ്. വല്ലവനും പിന്തിരിഞ്ഞു കളയുന്ന പക്ഷം വേദനയേറിയ ശിക്ഷ അവന്നു നല്‍കുന്നതാണ്."
  },
  {
    "surah_number": 48,
    "verse_number": 18,
    "content":
        "ആ മരത്തിന്‍റെ ചുവട്ടില് വെച്ച് സത്യവിശ്വാസികള് നിന്നോട് പ്രതിജ്ഞ ചെയ്തിരുന്ന സന്ദര്‍ഭത്തില് തീര്‍ച്ചയായും അല്ലാഹു അവരെ പറ്റി തൃപ്തിപ്പെട്ടിരിക്കുന്നു. അവരുടെ ഹൃദയങ്ങളിലുള്ളത് അവന് അറിയുകയും, അങ്ങനെ അവര്‍ക്ക് മനസ്സമാധാനം ഇറക്കികൊടുക്കുകയും, ആസന്നമായ വിജയം അവര്‍ക്ക് പ്രതിഫലമായി നല്‍കുകയും ചെയ്തു."
  },
  {
    "surah_number": 48,
    "verse_number": 19,
    "content":
        "അവര്‍ക്ക് പിടിച്ചെടുക്കുവാന് ധാരാളം സമരാര്‍ജിത സ്വത്തുകളും (അവന് നല്‍കി) അല്ലാഹു പ്രതാപിയും യുക്തിമാനുമാകുന്നു."
  },
  {
    "surah_number": 48,
    "verse_number": 20,
    "content":
        "നിങ്ങള


1, Main.player[this.target].Center, 1, 1))
              NPC.NewNPC((int) ((double) this.position.X + (double) (this.width / 2) + (double) this.velocity.X), (int) ((double) this.position.Y + (double) (this.height / 2) + (double) this.velocity.Y), 112, 0, 0.0f, 1f, 0.0f, 0.0f, (int) byte.MaxValue);
          }
        }
      }
      bool flag1 = false;
      float num1 = 0.2f;
      switch (this.type)
      {
        case 10:
        case 39:
        case 95:
        case 117:
        case 510:
          flag1 = true;
          break;
        case 513:
          flag1 = !Main.player[this.target].ZoneUndergroundDesert;
          num1 = 0.1f;
          break;
        case 621:
          flag1 = false;
          break;
      }
      if (this.type >= 13 && this.type <= 15)
        this.realLife = -1;
      else if ((double) this.ai[3] > 0.0)
        this.realLife = (int) this.ai[3];
      if (this.target < 0 || this.target == (int) byte.MaxValue || Main.player[this.target].dead || flag1 && (double) Main.player[this.target].position.Y < Main.worldSurface * 16.0)
        this.TargetClosest(true);
      if (Main.player[this.target].dead || flag1 && (double) Main.player[this.target].position.Y < Main.worldSurface * 16.0)
      {
        this.EncourageDespawn(300);
        if (flag1)
          this.velocity.Y += num1;
      }
      if (this.type == 621 && Main.dayTime)
      {
        this.EncourageDespawn(60);
        ++this.velocity.Y;
      }
      if (Main.netMode != 1)
      {
        if (this.type == 87 && (double) this.ai[0] == 0.0)
        {
          this.ai[3] = (float) this.whoAmI;
          this.realLife = this.whoAmI;
          int index1 = this.whoAmI;
          for (int index2 = 0; index2 < 14; ++index2)
          {
            int Type = 89;
            if (index2 == 1 || index2 == 8)
            {
              Type = 88;
            }
            else
            {
              switch (index2)
              {
                case 11:
                  Type = 90;
                  break;
                case 12:
                  Type = 91;
                  break;
                case 13:
                  Type = 92;
                  break;
              }
            }
            int number = NPC.NewNPC((int) ((double) this.position.X + (double) (this.width / 2)), (int) ((double) this.position.Y + (double) this.height), Type, this.whoAmI, 0.0f, 0.0f, 0.0f, 0.0f, (int) byte.MaxValue);
            Main.npc[number].ai[3] = (float) this.whoAmI;
            Main.npc[number].realLife = this.whoAmI;
            Main.npc[number].ai[1] = (float) index1;
            Main.npc[number].CopyInteractions(this);
            Main.npc[index1].ai[0] = (float) number;
            NetMessage.SendData(23, -1, -1, (NetworkText) null, number, 0.0f, 0.0f, 0.0f, 0, 0, 0);
            index1 = number;
          }
        }
        if (this.type == 454 && (double) this.ai[0] == 0.0)
        {
          this.ai[3] = (float) th


 "5e6aa3a35c03174a701a675b",
 *   "name": "Juan Carlos",
 *   "lastname": "Cadavid",
 *   "email": "jucacar35@hotmail.com",
 *   "roles": [
 *       "admin",
 *       "customer",
 *       "support"
 *   ]
 *}
 *
 * @apiError UserNotFound validate email.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 404 Not Found
 *     { message: "DeleteUserNotFound", error }
 */
router.delete(
  '/user/:email',
  passport.authenticate('jwt', {session: false}),
  permit(['admin', 'support']),
  userController.deleteUser,
);

/**
 * @api {post} /user/signup signup user
 * @apiName signupUser
 * @apiGroup User
 *
 * @apiParam {String} name  name of the user.
 * @apiParam {String} lastname  lastname of the user.
 * @apiParam {String} email  email of the user.
 * @apiParam {String} password  password of the user.

 * @apiSuccess {String} id id of the user.
 * @apiSuccess {String} name  name of the user.
 * @apiSuccess {String} lastname  lastname of the user.
 * @apiSuccess {String} email  email of the user.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 * {
 *     "message": "User created successfully",
 *     "user": {
 *         "user": {
 *             "name": "Juan prueba",
 *             "lastname": "prueba",
 *             "email": "prueba@hotmail.com",
 *             "roles": [
 *                 "customer"
 *             ],
 *             "id": "5e7bf96fd8156984985e7b26"
 *         }
 *     }
 * }
 *
 * @apiError UserNotFound Validate parameters.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 404 Not Found
 *    { message: "Error", error }
 */
router.post('/user/signup', userController.signUp);

/**
 * @api {post} /user/signin signin user
 * @apiName signinUser
 * @apiGroup User
 *
 * @apiParam {string} email  email of the user param header.
 * @apiParam {String} password  password of the user.
 *
 * @apiSuccess {String} token token of the user.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 *    {
 *      "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI1ZTZhYWI5ZWI0Y"
 *   }
 *
 * @apiError UserNotFound The id of the User was not found.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 404 Not Found
 *    {
 *   "msg": "Validate Credentials"
 *
 */
router.post('/user/signin', userController.signIn);

/**
 * @api {put} /user/:email Recover password of user
 * @apiName RecoverPassword
 * @apiGroup User
 *
 * @apiParam {string} email  email of the user param header.
 *
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 * { message: 'Your password generated successfully and was sent to your email address' }
 *
 * @apiError UserNotFound The id of the User was not found.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 404 Not Found
 *    { message: "UserNotFound", error }
 */
router.put('/user/recoverpassword/:email', userController.recoverPassword);

/**
 * @api {put} /user/:email Update password of user
 * @apiName UpdatePassword
 * @apiGroup User
 *
 * @apiParam {string} email  email of the user param header.
 * @apiParam {String} password  Current password of the use


:
			continue
		}
		if i < len(c.columns)-1 {
			buf = append(buf, ',')
		}
	}
	buf = append(buf, ']')
	return buf, nil
}

func (c *Income) MarshalCSV() ([]string, error) {
	dec := c.params.Decimals
	res := make([]string, len(c.columns))
	for i, v := range c.columns {
		switch v {
		case "row_id":
			res[i] = strconv.FormatUint(c.RowId, 10)
		case "cycle":
			res[i] = strconv.FormatInt(c.Cycle, 10)
		case "account_id":
			res[i] = strconv.FormatUint(c.AccountId.U64(), 10)
		case "address":
			res[i] = strconv.Quote(c.ctx.Indexer.LookupAddress(c.ctx, c.AccountId).String())
		case "balance":
			res[i] = strconv.FormatFloat(c.params.ConvertValue(c.Balance), 'f', dec, 64)
		case "delegated":
			res[i] = strconv.FormatFloat(c.params.ConvertValue(c.Delegated), 'f', dec, 64)
		case "own_stake":
			res[i] = strconv.FormatFloat(c.params.ConvertValue(c.OwnStake), 'f', dec, 64)
		case "staking_balance":
			res[i] = strconv.FormatFloat(c.params.ConvertValue(c.StakingBalance), 'f', dec, 64)
		case "n_delegations":
			res[i] = strconv.FormatInt(c.NDelegations, 10)
		case "n_stakers":
			res[i] = strconv.FormatInt(c.NStakers, 10)
		case "n_baking_rights":
			res[i] = strconv.FormatInt(c.NBakingRights, 10)
		case "n_endorsing_rights":
			res[i] = strconv.FormatInt(c.NEndorsingRights, 10)
		case "luck":
			res[i] = strconv.FormatFloat(c.params.ConvertValue(c.Luck), 'f', dec, 64)
		case "luck_percent":
			res[i] = strconv.FormatFloat(float64(c.LuckPct)/100, 'f', 2, 64)
		case "contribution_percent":
			res[i] = strconv.FormatFloat(float64(c.ContributionPct)/100, 'f', 2, 64)
		case "performance_percent":
			res[i] = strconv.FormatFloat(float64(c.PerformancePct)/100, 'f', 2, 64)
		case "n_blocks_baked":
			res[i] = strconv.FormatInt(c.NBlocksBaked, 10)
		case "n_blocks_proposed":
			res[i] = strconv.FormatInt(c.NBlocksProposed, 10)
		case "n_blocks_not_baked":
			res[i] = strconv.FormatInt(c.NBlocksNotBaked, 10)
		case "n_blocks_endorsed":
			res[i] = strconv.FormatInt(c.NBlocksEndorsed, 10)
		case "n_blocks_not_endorsed":
			res[i] = strconv.FormatInt(c.NBlocksNotEndorsed, 10)
		case "n_slots_endorsed":
			res[i] = strconv.FormatInt(c.NSlotsEndorsed, 10)
		case "n_seeds_revealed":
			res[i] = strconv.FormatInt(c.NSeedsRevealed, 10)
		case "expected_income":
			res[i] = strconv.FormatFloat(c.params.ConvertValue(c.ExpectedIncome), 'f', dec, 64)
		case "total_income":
			res[i] = strconv.FormatFloat(c.params.ConvertValue(c.TotalIncome), 'f', dec, 64)
		case "baking_income":
			res[i] = strconv.FormatFloat(c.para


1.12-.34.29-.41.51l-.14.59c-.02.09-.03.16-.03.22zm.78-2.9c0 .22.08.41.25.58.16.16.35.24.57.24.24 0 .43-.08.59-.23.16-.16.23-.35.23-.59 0-.23-.08-.42-.23-.58s-.35-.23-.59-.23-.43.08-.59.23a.8.8 0 00-.23.58zm.63-2.27c-.01.15.03.31.13.47s.25.26.45.3c.23.06.44.04.64-.06.19-.1.33-.29.41-.56l.27-.9c.07-.22.05-.43-.07-.63a.867.867 0 00-.53-.4c-.22-.07-.43-.04-.64.08s-.34.3-.41.53l-.22.9c-.02.08-.03.17-.03.27zm2.75 2.15c0 .16.05.32.15.48s.26.27.46.33c.03 0 .08.01.14.02.06.01.1.02.14.02.41 0 .66-.22.76-.66l.14-.6c.07-.21.05-.42-.07-.63a.809.809 0 00-.51-.41c-.25-.06-.48-.04-.68.08s-.34.29-.41.53l-.09.59c0 .02-.01.07-.02.12 0 .05-.01.09-.01.13zm.74-2.96c0 .22.08.42.25.57.15.16.34.24.57.24.24 0 .43-.08.59-.23s.23-.35.23-.58c0-.24-.08-.43-.23-.59s-.35-.23-.59-.23-.43.08-.59.23-.23.35-.23.59zm.61-2.31c0 .17.05.33.16.48s.27.26.49.32c.02 0 .06.01.12.02s.11.02.14.02c.1 0 .22-.03.36-.09.21-.11.35-.29.41-.52l.24-.9c.06-.23.04-.44-.08-.63a.827.827 0 00-.51-.4c-.23-.07-.44-.05-.64.06s-.32.27-.39.51l-.28.91c0 .02-.01.06-.02.12.01.03 0 .07 0 .1zm.07-10.05c.32-.58.76-1.02 1.31-1.34.56-.32 1.13-.47 1.73-.46.09 0 .19.01.3.03v.31c-.01.98.25 1.9.77 2.76.53.86 1.27 1.5 2.22 1.94-.19.41-.46.78-.8 1.11-.92-.76-2-1.14-3.23-1.14h-.31c-.31-1.31-.97-2.38-1.99-3.21z"/></svg>';
  static const String owm_night_612 =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="30" height="30" preserveAspectRatio="xMidYMid meet" viewBox="0 0 30 30"><path fill="currentColor" d="M4.07 16.93c0 1.33.47 2.47 1.4 3.43s2.07 1.47 3.4 1.51c.12 0 .18-.06.18-.17v-1.34c0-.11-.06-.17-.18-.17-.85-.04-1.58-.39-2.18-1.03s-.91-1.39-.91-2.23c


-bottom: 1px dashed #B7C2C5;
}

body.dashboard div#main div.post strong {
    font-weight: bold;
    font-size: 14px;
}

body.dashboard div#main div.post span {
    font-weight: normal;
    font-size: 10px;
}

body.dashboard div#main div.widget.gestrew div.message{background:url("/view/css/project/view/invest/header_beak.png") #CCE5E6 no-repeat left bottom; color:#58595B;padding:20px 20px 30px 20px; height:auto;overflow:auto;}

/* = recompensas
***************************/
body.dashboard div#main div.widget.gestrew div.rewards{height:auto;overflow:auto;margin-top:10px;}
body.dashboard div#main div.widget.gestrew div.reward{background:#E4C9E2;width:197px;min-height:175px;padding:10px;margin-right:10px;float:left;position:relative;margin-bottom:10px;height:190px;}
body.dashboard div#main div.widget.gestrew div.reward.last{margin-right:0;}
body.dashboard div#main div.widget.gestrew div.reward div.orden{color:#fff;display:inline-block;font-weight:bold;font-size:13pt;background-color:#e7e7e7;border:2px solid #a7a9ac;color:#a7a9ac;width:20px;text-align:center;}
body.dashboard div#main div.widget.gestrew div.reward span.aporte{color: #96238F;display: inline-block;font-size: 8pt;text-transform: uppercase;line-height:22px;}
body.dashboard div#main div.widget.gestrew div.reward span.num{font-size:12pt;}
body.dashboard div#main div.widget.gestrew div.reward span.aporte > span.euro{ background:url('/view/css/euro/violet/m.png') no-repeat; height:20px; width:20px;display:inline-block;}
body.dashboard div#main div.widget.gestrew div.reward span.cofinanciadores{color:#40509F;display:block;text-transform:uppercase;margin-left:29px;font-size:8pt;line-height:20px;}
body.dashboard div#main div.widget.gestrew div.reward div.tiporec{display:block;border-bottom:#8D878E 1px solid;margin-bottom:5px;}
body.dashboard div#main div.widget.gestrew div.reward ul { list-style: none outside none; padding:0px; margin: 0px 0px 3px 0px; float:none; font-size:12px; }
body.dashboard div#main div.widget.gestrew div.reward div.tiporec ul li { background:none no-repeat scroll 0px 0px transparent; padding: 0px 0px 0px 29px; min-height: 34px; }
body.dashboard div#main div.widget.gestrew div.reward div.tiporec ul li.file { background-image: url('/view/css/icon/s/file.png'); }
body.dashboard div#main div.widget.gestrew div.reward div.tiporec ul li.money { background-image: url('/view/css/icon/s/money.png'); }
body.dashboard div#main div.widget.gestrew div.reward div.tiporec ul li.code { background-image: url('/view/css/icon/s/code.png'); }
body.dashboard div#main div.widget.gestrew div.reward div.tiporec ul li.service { background-image: url('/view/css/icon/s/service.png'); }
body.dashboard div#main div.widget.gestrew div.reward div.tiporec ul li.manual { background-image: url('/view/css/icon/s/manual.png'); }
body.dashboard div#main div


中心的欧氏距离， 按距离最近的准则将它们分到距离它们最近的聚类中心(最相似) 所对应的类；
3. 更新聚类中心:将每个类别中所有对象所对应的均值作为该类别 的聚类中心，计算目标函数的值；
4. 判断聚类中心和目标函数的值是否发生改变，若不变，则输出结 果，若改变，则返回2)。

### 降维

降维的目的就是将原始样本数据的维度𝑑降低到一个更小的数𝑚，且尽量使得样本蕴含信息量损失最小，或还原数据时产生的误差最小。比如主成分分析法...

降维的优势：

- 数据在低维下更容易处理、更容易使用；
- 相关特征，特别是重要特征更能在数据中明确的显示出来；
- 如果只有二维或者三维的话，能够进行可视化展示；
- 去除数据噪声，降低算法开销等。

# 单动作多智能体-写诗

我们可以模拟老师带教学生的模式。来让学生智能体写出一个作品，然后让老师智能体给出改进意见，然后再修改，再给意见，如此反复。现在我们设定，需要多智能体系统为我们根据我们给定的主题提供一篇优美的英文诗，除了完成写作的 agent 外，我们再设定一名精通诗句的老师来查看并修改学生的作品。

**流程**
系统首先接收用户的需求（写关于XX主题的诗），在系统中，当学生关注到布置的题目后就会开始创作，当老师发现学生写作完成后就会给学生提出意见，根据老师给出的意见，学生将修改自己的作品，直到设定循环结束。

**插入模块**

```python
import asyncio

from metagpt.actions import Action, UserRequirement
from metagpt.logs import logger
from metagpt.roles import Role
from metagpt.schema import Message
from metagpt.environment import Environment

from metagpt.const import MESSAGE_ROUTE_TO_ALL
```

声明一个名为 classroom 的 env，我们将所有的 role 都放在其中

```python
classroom = Environment()
```

**定


] === \".\") {\n                k = k - 1 | 0;\n              }\n              s = s.slice(0, k + 1 | 0);\n            }\n            \n          }\n          break;\n      default:\n        \n    }\n  } else {\n    s = \"inf\";\n    f[/* filter */2] = \" \";\n  }\n  return finish_formatting(f, s);\n}\n\nfunction float_of_string (s,exn){ \n\n    var res = +s;\n    if ((s.length > 0) && (res === res))\n        return res;\n    s = s.replace(/_/g, \"\");\n    res = +s;\n    if (((s.length > 0) && (res === res)) || /^[+-]?nan$/i.test(s)) {\n        return res;\n    };\n    if (/^\\+?inf(inity)?$/i.test(s))\n        return Infinity;\n    if (/^-inf(inity)?$/i.test(s))\n        return -Infinity;\n    throw exn;\n\n};\n\nfunction caml_float_of_string(s) {\n  return float_of_string(s, [\n              Caml_builtin_exceptions.failure,\n              \"float_of_string\"\n            ]);\n}\n\nvar caml_nativeint_format = caml_format_int;\n\nvar caml_int32_format = caml_format_int;\n\nvar caml_int32_of_string = caml_int_of_string;\n\nvar caml_nativeint_of_string = caml_int_of_string;\n\nexports.caml_format_float = caml_format_float;\nexports.caml_format_int = caml_format_int;\nexports.caml_nativeint_format = caml_nativeint_format;\nexports.caml_int32_format = caml_int32_format;\nexports.caml_float_of_string = caml_float_of_string;\nexports.caml_int64_format = caml_int64_format;\nexports.caml_int_of_string = caml_int_of_string;\nexports.caml_int32_of_string = caml_int32_of_string;\nexports.caml_int64_of_string = caml_int64_of_string;\nexports.caml_nativeint_of_string = caml_nativeint_of_string;\n/* No side effect */\n\n\n//# sourceURL=webpack:///./node_modules/bs-platform/lib/js/caml_format.js?");

/***/ }),

/***/ "./node_modules/bs-platform/lib/js/caml_int32.js":
/*!*******************************************************!*\
  !*** ./node_modules/bs-platform/lib/js/caml_int32.js ***!
  \*******************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
eval("\n\nvar Caml_builtin_exceptions = __webpack_require__(/*! ./caml_builtin_exceptions.js */ \"./node_modules/bs-platform/lib/js/caml_builtin_exceptions.js\");\n\nfunction div(x, y) {\n  if (y === 0) {\n    throw Caml_builtin_exceptions.division_by_zero;\n  } else {\n    return x / y | 0;\n  }\n}\n\nfunction mod_(x, y) {\n  if (y === 0) {\n    throw Caml_builtin_exceptions.division_by_zero;\n  } else {\n    return x % y;\n  }\n}\n\nfunction caml_bswap16(x) {\n  return ((x & 255) << 8) | ((x & 65280) >>>


.hasText(driverClassName)) {
            config.setDriverClassName(driverClassName);
        }
        if (Boolean.FALSE.equals(dataSourceProperty.getLazy())) {
            try {
                return new BeeDataSource(config);
            } catch (Exception e) {
                throw new ErrorCreateDataSourceException(
                    "dynamic-datasource create datasource named [" + dataSourceProperty.getPoolName() + "] error", e);
            }
        }
        BeeDataSource beeDataSource = new BeeDataSource();
        try {
            copyToMethod.invoke(config, beeDataSource);
        } catch (InvocationTargetException | IllegalAccessException e) {
            e.printStackTrace();
        }
        return beeDataSource;
    }

    @Override
    public boolean support(DataSourceProperty dataSourceProperty) {
        Class<? extends DataSource> type = dataSourceProperty.getType();
        return type == null || DdConstants.BEECP_DATASOURCE.equals(type.getName());
    }
}/*
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You under the Apache License, Version 2.0
 * (the "License"); you may not use this file except in compliance with
 * the License.  You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.baomidou.kisso.signature;

import com.baomidou.kisso.common.signature.Signature;
import com.baomidou.kisso.exception.AuthenticationException;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;

import java.util.*;

import static com.baomidou.kisso.common.util.JoinUtil.join;

public class SignatureTest {

    @Test
    public void validSignature() {
        new Signature("somekey", "hmac-sha256", "yT/NrPI9mKB5R7FTLRyFWvB+QLQOEAvbGmauC0tI+Jg=", "date", "accept");
    }

    @Test
    public void nullKey() {
        new Signature(null, "hmac-sha256", "yT/NrPI9mKB5R7FTLRyFWvB+QLQOEAvbGmauC0tI+Jg=", "date", "accept");
    }

    @Test
    public void nullSignature() {
        new Signature("somekey", "hmac-sha256", null, "date", "accept");
    }

    @Test
    public void nullAlgorithm() {
        new Signature("somekey", (String) null, "yT/NrPI9mKB5R7FTLRyFWvB+QLQOEAvbGmauC0tI+Jg=", "date", "accept");
    }

    @Test
    public void nullHeaders() {
        final Signature signature = new Signature("somekey", "hmac-sha256", "yT/NrPI9mKB5R7FTLRyFWvB+QLQOEAvbGmauC0tI+Jg=");
        Assertions.assertEquals(1, signature.getHeaders().size()); // should contain at least the Date which is required
        Assertions.assertEquals("date", signature.getHeaders().get(0).toLowerCase());
    }

    @Test
    public void roundTripTest() throws Exception {
        final Signature expected = new Signature("somekey", "hmac-sha256", "yT/NrPI9mKB5R7FTLRyFWvB+QLQOEAvbGmauC0tI+Jg=", "date", "accept");
        final Signature actual = Signature.fromString(expected.toString());

        assertSignature(expected, actual);
    }

    @Test
    public void testFromString(


xecute(DataRuntime runtime, String random, Metadata meta, ACTION.DDL action, Run run) {
		return super.execute(runtime, random, meta, action, run);
	}
	/* *****************************************************************************************************************
	 * 													table
	 * -----------------------------------------------------------------------------------------------------------------
	 * [调用入口]
	 * boolean create(DataRuntime runtime, Table meta)
	 * boolean alter(DataRuntime runtime, Table meta)
	 * boolean drop(DataRuntime runtime, Table meta)
	 * boolean rename(DataRuntime runtime, Table origin, String name)
	 * [命令合成]
	 * List<Run> buildCreateRun(DataRuntime runtime, Table meta)
	 * List<Run> buildAlterRun(DataRuntime runtime, Table meta)
	 * List<Run> buildAlterRun(DataRuntime runtime, Table meta, Collection<Column> columns)
	 * List<Run> buildRenameRun(DataRuntime runtime, Table meta)
	 * List<Run> buildDropRun(DataRuntime runtime, Table meta)
	 * [命令合成-子流程]
	 * List<Run> buildAppendCommentRun(DataRuntime runtime, Table table)
	 * List<Run> buildChangeCommentRun(DataRuntime runtime, Table table)
	 * StringBuilder checkTableExists(DataRuntime runtime, StringBuilder builder, boolean exists)
	 * StringBuilder primary(DataRuntime runtime, StringBuilder builder, Table table)
	 * time runtime, StringBuilder builder, Table table)
	 * StringBuilder comment(DataRuntime runtime, StringBuilder builder, Table table)
	 * StringBuilder partitionBy(DataRuntime runtime, StringBuilder builder, Table table)
	 * StringBuilder partitionOf(DataRuntime runtime, StringBuilder builder, Table table)
	 ******************************************************************************************************************/
	/**
	 * table[调用入口]

	 * 创建表,执行的命令通过meta.ddls()返回
	 * @param runtime 运行环境主要包含驱动适配器 数据源或客户端
	 * @param meta 表
	 * @return boolean 是否执行成功
	 * @throws Exception DDL异常
	 */
	@Override
	public boolean create(DataRuntime runtime, Table meta) throws Exception {
		return super.create(runtime, meta);
	}

	/**
	 * table[调用入口]

	 * 修改表,执行的命令通过meta.ddls()返回
	 * @param runtime 运行环境主要包含驱动适配器 数据源或客户端
	 * @param meta 表
	 * @return boolean 是否执行成功
	 * @throws Exception DDL异常
	 */
	@Override
	public boolean alter(DataRuntime runtime, Table meta) throws Exception {
		return super.alter(runtime, meta);
	}

	/**
	 * table[调用入口]

	 * 删除表,执行的命令通过meta.ddls()返回
	 * @param runtime 运行环境主要包含驱动适配器 数据源或客户端
	 * @param meta 表
	 * @return boolean 是否执行成功
	 * @throws Exception DDL异常
	 */
	@Override
	public boolean drop(DataRuntime runtime, Table meta) throws Exception {
		return super.drop(runtime, meta);
	}

	/**
	 * table[调用入口]

	 * 重命名表,执行的命令通过meta.ddls()返回
	 * @param runtime 运行环境主要包含驱动适配器 数据源或客户端
	 * @param origin 原表
	 * @param name 新名�


	interfaceWithThreeMethods.A();
				interfaceWithThreeMethods.C();
			}

			mockRepository.ReplayAll();

			interfaceWithThreeMethods.A();
			try
			{
				interfaceWithThreeMethods.B();
			}
			catch { /* valid for code under test to catch all */ }
			interfaceWithThreeMethods.C();

			Assert.Throws<ExpectationViolationException>(
				"Unordered method call! The expected call is: 'Ordered: { IInterfaceWithThreeMethods.C(); }' but was: 'IInterfaceWithThreeMethods.B();'",
				() => mockRepository.VerifyAll());
		}
	}

	public interface IInterfaceWithThreeMethods
	{
		void A();
		void B();
		void C();
	}

	public class SimpleOperations
	{
		public virtual int AddTwoValues(int x, int y)
		{
			return x + y;
		}
	}
}


mary>
Formats the value using the given formatter. Read more

source§
impl<'s> Replacer for NoExpand<'s>

source§
fn replace_append(&mut self, _: &Captures<'_>, dst: &mut Vec<u8>)

Appends possibly empty data to dst to replace the current match. Read more

source§
fn no_expansion(&mut self) -> Option<Cow<'_, [u8]>>

Return a fixed unchanging replacement byte string. Read more

source§


 团队已承诺将其序列器的所有利润用于公共物品资助实验，具体细节仍在制定中。他们期待通过这一机制，为公共物品项目创造类似初创企业的资金循环，促进社区的可持续发展。

https://medium.com/ethereum-optimism/retroactive-public-goods-funding-33c9b7d00f0c

**OP Stack 是 Optimism 的核心基础架构，它是一个用于构建去中心化区块链和扩展解决方案的模块化、开源软件栈（技术栈）。**

简单来说，OP Stack 是一组工具和组件的集合，用于构建和运行区块链（尤其是扩展以太坊的区块链）。它是 Optimism 网络的技术基础，也是 Optimism 为实现其 “Superchain” 愿景开发的关键技术。

**OP Stack 的核心目标**

1. 模块化：每个功能（如共识、执行、数据可用性）都被设计为一个模块，开发者可以根据需要进行定制和替换。
2. 可扩展性：OP Stack 专注于为以太坊提供高效的扩展解决方案，使得更多的交易可以更快、更便宜地执行。
3. 开源与可组合性：OP Stack 是完全开源的，任何人都可以基于它构建自己的区块链，同时确保与以太坊和其他基于 OP Stack 的区块链保持互操作性。
4. Superchain 生态系统：OP Stack 支持构建一个由许多 L2 区块链组成的 “超级链（Superchain）”，这些链在共享安全性和互操作性方面无缝协作。

**OP Stack 的模块**

OP Stack 是模块化的，允许开发者根据自己的需求选择和定制每个组件。主要模块包括：
1. 执行模块（Execution Layer）：
* 负责运行智能合约和处理交易。
* 通常使用以太坊虚拟机（EVM）或其他兼容虚拟机。
2. 共识模块（Consensus Layer）：
* 确保网络节点就区块顺序达成一致。
* 可以选择不同的共识机制（如 PoW、PoS）。
3. 数据可用性模块（Data Availability Layer）：
* 确保所有数据在区块链上都是可验证和可用的。
4. 聚合模块（Rollup Layer）：
* 支持 Rollup 技术，将多个交易打包并提交到以太坊主网，从而降低成本和提高效率。
5. 桥接模块（Bridging Layer）：
* 实现与以太坊主网和其他区块链的无缝交互。

**OP Stack 的优势


c2bb67b76c4e49
        #16 9% jascha, jascha@relayable.org - 2479739594ed5802a96703e5a870b515d986982474a71feae180e8ecffa302c6
        #17 8% Nakadaimon, Nakadaimon@nostrplebs.com - 803a613997a26e8714116f99aa1f98e8589cb6116e1aaa1fc9c389984fcd9bb8
        #18 8% KeithMukai, KeithMukai@nostr.seedsigner.com - 5b0e8da6fdfba663038690b37d216d8345a623cc33e111afd0f738ed7792bc54
        #19 8% TheGuySwann, theguyswann@NostrVerified.com - b0b8fbd9578ac23e782d97a32b7b3a72cda0760761359bd65661d42752b4090a
        #20 8% dk, dk@stacker.news - b708f7392f588406212c3882e7b3bc0d9b08d62f95fa170d099127ece2770e5e
        #21 7% zerohedge, npub1z7eqn5603ltuxr77w70t3sasep8hyngzr6lxqpa9hfcqjwe9wmdqhw0qhv@nost.vip - 17b209d34f8fd7c30fde779eb8c3b0c84f724d021ebe6007a5ba70093b2576da
        #22 7% miljan, miljan@primal.net - d61f3bc5b3eb4400efdae6169a5c17cabf3246b514361de939ce4a1a0da6ef4a
        #23 7% jared, jared@nostrplebs.com - 92e3aac668edb25319edd1d87cadef0b189557fdd13b123d82a19d67fd211909
        #24 7% radii, radii@orangepill.dev - acedd3597025cb13b84f9a89643645aeb61a3b4a3af8d7ac01f8553171bf17c5
        #25 7% katie, _@katieannbaker.com - 07eced8b63b883cedbd8520bdb3303bf9c2b37c2c7921ca5c59f64e0f79ad2a6
        #26 7% giacomozucco, giacomozucco@BitcoinNostr.com - ef151c7a380f40a75d7d1493ac347b6777a9d9b5fa0aa3cddb47fc78fab69a8b
        #27 7% kr, kr@stacker.news - 08b80da85ba68ac031885ea555ab42bb42231fde9b690bbd0f48c128dfbf8009
        #28 7% phil, phil@nostrpurple.com - e07773a92a610a28da20748fdd98bfb5af694b0cad085224801265594a98108a
        #29 7% angela, angela@nostr.world - 2b1964b885de3fcbb33777874d06b05c254fecd561511622ce86e3d1851949fa
        #30 7% mason 𓄀 𓅦, mason@lacosanostr.com - 5ef92421b5df0ed97df6c1a98fc038ea7962a29e7f33a060f7a8ddeb9ee587e9
        #31 7% Lau, lau@nostr.report - 5a9c48c8f4782351135dd89c5d8930feb59cb70652ffd37d9167bf922f2d1069
        #32 7% Rex Damascus , dam


untei para o papel noel se ele roía as unhas, e ele: – Rou, rou, rou.",
            "Hoje o dia está tão nublado que uma nuvem chegou pra outra e falou: – Num vem que não tem.",
            "O que é um fumo de maconha em cima do jornal?\n\nUm baseado em fatos reais.",
            "Qual a diferença do lago com a padaria?\n\nNo lago há sapinho, na padaria assa pão.",
            "Por que o médico que trabalha de noite usa verde?\n\nÉ porque ele está de plantão.",
            "O que o tomate foi fazer no banco?\n\nFoi tirar o extrato.")

        override suspend fun execute(
            context: UnleashedContext,
            args: SlashCommandArguments
        ) {
            context.reply(false) {
                embed {
                    author("Kenji do Loop Infinito", null, "https://stuff.loritta.website/kenji.jpg")

                    description = "${bemBoladas.random()} ${Emotes.LoriSmile}"
                }
            }
        }

        override suspend fun convertToInteractionsArguments(
            context: LegacyMessageCommandContext,
            args: List<String>
        ): Map<OptionReference<*>, Any?> = emptyMap()
    }
}package net.perfectdreams.loritta.morenitta.interactions.vanilla.economy

import net.dv8tion.jda.api.interactions.IntegrationType
import net.perfectdreams.loritta.common.commands.CommandCategory
import net.perfectdreams.loritta.i18n.I18nKeysData
import net.perfectdreams.loritta.morenitta.LorittaBot
import net.perfectdreams.loritta.morenitta.interactions.commands.SlashCommandDeclarationWrapper
import net.perfectdreams.loritta.morenitta.interactions.commands.slashCommand
import java.util.*

class SonhosCommand(private val loritta: LorittaBot) : SlashCommandDeclarationWrapper {
    companion object {
        val I18N_PREFIX = I18nKeysData.Commands.Command.Sonhos
        val CATEGORY_I18N_PREFIX = I18nKeysData.Commands.Category.Economy
        val TRANSACTIONS_I18N_PREFIX = I18nKeysData.Commands.Command.Transactions
        val PAY_I18N_PREFIX = I18nKeysData.Commands.Command.Pay
        val SONHOS_RANK_I18N_PREFIX = I18nKeysData.Commands.Command.Sonhosrank
    }

    override fun command() = slashCommand(I18N_PREFIX.Label, CATEGORY_I18N_PREFIX.RootCommandDescription, CommandCategory.ECONOMY, UUID.fromString("a2f8ef4e-ba83-4fb0-a14f-12a7168acf48")) {
        this.enableLegacyMessageSupport = true
        this.integrationTypes = listOf(IntegrationType.GUILD_INSTALL, IntegrationType.USER_INSTALL)

        subcommand(I18nKeysData.Commands.Command.Sonhosatm.Label, I18nKeysData.Commands.Command.Sonhosatm.Description, UUID.fromString("8f1beb59-63b1-4441-b841-d20df01a7ab1")) {
            this.alternativeLegacyAbsoluteCommandPaths.apply {
                add("sonhos")
                add("atm")
                add("bal")
                add("balance")
            }
            executor = SonhosAtmExecutor(loritta)
        }

        subcommand(PAY_I18N_PREFIX.Label, PAY_I18N_PREFIX.Description, UUID.


#pragma once

#include "mc/_HeaderOutputPredefine.h"

// auto generated inclusion list
#include "mc/external/cricket/ProtocolType.h"

// auto generated forward declare list
// clang-format off
namespace rtc { class SocketAddress; }
// clang-format on

namespace cricket {

struct RelayServerConfig {
public:
    // member variables
    // NOLINTBEGIN
    ::ll::UntypedStorage<8, 24> mUnka997b0;
    ::ll::UntypedStorage<8, 64> mUnkd81b79;
    ::ll::UntypedStorage<4, 4>  mUnk765d45;
    ::ll::UntypedStorage<8, 24> mUnkf894b9;
    ::ll::UntypedStorage<8, 24> mUnkb36e86;
    ::ll::UntypedStorage<8, 8>  mUnk3888a0;
    ::ll::UntypedStorage<8, 32> mUnkb68e75;
    // NOLINTEND

public:
    // prevent constructor by default
    RelayServerConfig& operator=(RelayServerConfig const&);

public:
    // member functions
    // NOLINTBEGIN
    MCNAPI RelayServerConfig();

    MCNAPI RelayServerConfig(::cricket::RelayServerConfig const&);

    MCNAPI RelayServerConfig(
        ::rtc::SocketAddress const& address,
        ::std::string_view          username,
        ::std::string_view          password,
        ::cricket::ProtocolType     proto
    );

    MCNAPI ~RelayServerConfig();
    // NOLINTEND

public:
    // constructor thunks
    // NOLINTBEGIN
    MCNAPI void* $ctor();

    MCNAPI void* $ctor(::cricket::RelayServerConfig const&);

    MCNAPI void* $ctor(
        ::rtc::SocketAddress const& address,
        ::std::string_view          username,
        ::std::string_view          password,
        ::cricket::ProtocolType     proto
    );
    // NOLINTEND

public:
    // destructor thunk
    // NOLINTBEGIN
    MCNAPI void $dtor();
    // NOLINTEND
};

} // namespace cricket


from decimal import Decimal
from datetime import datetime
from document_parser import DocumentParser

class BinanceXlsxParser(DocumentParser):
    # WARNING: You must download your "Trade History" from Binance, **NOT** "Order History"
    # Order History has a completely different formatting which will not work.
    def __init__(self, *args, **kwargs):
        kwargs['exchange_name'] = 'binance'
        kwargs['header'] = {
            'created_at': 'Date(UTC)',
            'amount': 'Amount',
            'fill_amount': 'Total',
            'currency_pair': 'Market',
            'type': 'Type',
            'price': 'Price',
        }
        kwargs['header_rows'] = 0
        super(BinanceXlsxParser, self).__init__(*args, **kwargs)

    def process_row(self, row):
        row['created_at'] = self.process_date(row)
        row['currency_pair'] = self.process_currency_pair(row)
        row['type'] = row['type'].lower()

        for key in ('amount', 'fill_amount', 'price'):
            row[key] = abs(Decimal(row[key]))
        return row

    def process_date(self, row):
        _date = row['created_at']
        if isinstance(_date, str):
            return datetime.strptime(_date, '%Y-%m-%d %H:%M:%S')
        if isinstance(_date, date):
            return datetime(_date.year, _date.month, _date.day)
        else:
            return _date

    def process_currency_pair(self, row):
        # WARNING: If USD is added to the quote pair, we'll need to change how we parse pairs below
        # because pair[-3:] will match USD even if it's TUSD, etc.
        quote_pairs = ['USDC', 'USDT', 'TUSD', 'BUSD', 'DAI', 'BTC', 'ETH']
        pair = row['currency_pair']

        if pair[-3:] in quote_pairs:
            first = pair[:-3]
            last =  pair[-3:]
        elif pair[-4:] in quote_pairs:
            first = pair[:-4]
            last = pair[-4:]
        else:
            raise Exception('Binance quote pair is not one of {}'.format(quote_pairs))

        if first == 'BCC':
            first = 'BCH'
        return first + "-" + last


et().getVoice();
		float posX = measure.getHeaderImpl().getLeftSpacing(layout) + measure.getPosX();
		float bestDiff = -1;
		TGBeatImpl bestBeat = null;
		Iterator<?> it = measure.getBeats().iterator();
		while(it.hasNext()){
			TGBeatImpl beat = (TGBeatImpl)it.next();
			if(!beat.getVoice(voice).isEmpty()){
				float diff = Math.abs(x - (posX + (beat.getPosX() + beat.getSpacing(layout))));
				if(bestDiff == -1 || diff < bestDiff){
					bestBeat = beat;
					bestDiff = diff;
				}
			}
		}
		if( bestBeat == null ){
			bestBeat = (TGBeatImpl) layout.getSongManager().getMeasureManager().getFirstBeat(measure.getBeats());
		}
		return bestBeat;
	}

	private TGString findSelectedString(TGMeasureImpl measure, float y) {
		TGString string = null;
		float stringSpacing = this.controller.getLayout().getStringSpacing();
		float minorDistance = 0;
		float firstStringY = measure.getPosY() + measure.getTs().getPosition(TGTrackSpacing.POSITION_TABLATURE);

		Iterator<?> it = measure.getTrack().getStrings().iterator();
		while(it.hasNext()){
			TGString currString = (TGString)it.next();
			float distanceX = Math.abs(y - (firstStringY + ((currString.getNumber() * stringSpacing) - stringSpacing)));
			if(string == null || distanceX < minorDistance){
				string = currString;
				minorDistance = distanceX;
			}
		}

		return string;
	}

	private Map<String, Object> findSmartMenuProperties(TGTrackImpl track, TGMeasureImpl measure, TGBeat beat, float x) {
		Map<String, Object> map = new HashMap<String, Object>();
		map.put(TGSongViewSmartMenu.REQUEST_SMART_MENU, true);

		TGLayout layout = this.controller.getLayout();
		float measureX1 = measure.getPosX();
		float measureX2 = (measureX1 + measure.getWidth(layout) + measure.getSpacing());
		float noteWidth = (((layout.getStringSpacing() - (2.0f * layout.getScale())) * 2) / 2f);

		float leftX1 = measureX1;
		float leftX2 = (leftX1 + measure.getHeaderImpl().getLeftSpacing(layout) + measure.getFirstNoteSpacing(layout) - noteWidth);
		float rightX1 = (measureX2 - measure.getHeaderImpl().getRightSpacing(layout) + noteWidth);
		float rightX2 = measureX2;
		if( x >= leftX1 && x <= leftX2 || x >= rightX1 && x <= rightX2) {
			map.put(TGSongViewSmartMenu.MEASURE_AREA_SELECTED, true);
		}

		return map;
	}

	private void callMoveTo(TGTrackImpl track, TGMeasureImpl measure, TGBeat beat, TGString string, Map<String, Object> smartMenuProperties) {
		TGActionProcessor tgActionProcessor = new TGActionProcessor(this.controller.getContext(), TGMoveToAction.NAME);
		tgActionProcessor.setAttribute(TGDocumentContextAttributes.ATTRIBUTE_TRACK, track);
		tgActionProcessor.setAttribute(TGDocumentContextAttributes.ATTRIBUTE_MEASURE, measure);
		tgActionProcessor.setAttribute(TGDocumentContextAttributes.ATTRIBUTE_BEAT, beat);
		tgActionProcessor.setAttribute(TGDocumentContextAttributes.ATTRIBUTE_STRING, string);

		if( smartMenuProperties != null ) {
			for(Map.Entry<String, Object> entry : smartMenuProperties.entrySet()) {
				tgActionProcessor.setAttribute(entry.getKey(), entry.getValue());
			}
		}
		tgActionProcessor.processOnNewThread();
	}
}
package app.tuxguitar.android.view.dialog.tremoloPicking