images/webapp-common-desktop-2x-0d02cd03.png);
          background-position: -70px -375px;
          background-size: 428px 427px; } }
.Modal.appUpsellModal .modalMask {
    top: 64px; }
.Modal.appUpsellModal .modalScroller {
    top: 64px; }
.Modal.fullScreenWhiteModal .modalMask {
    background-color: #fff; }
.Modal.fullScreenWhiteModal .modalScroller {
    overflow-x: auto;
    overflow-y: hidden; }
.Modal.fullScreenWhiteModal .closeModal {
    position: fixed;
    right: 14px;
    top: 18px;
    z-index: 1000; }
.Modal.fullScreenWhiteModal .closeModal em {
      width: 17px;
      height: 16px;
      background: url(https://s.pinimg.com/webapp/style/images/webapp-common-desktop-1x-28441dec.png) -358px -342px no-repeat; }
@media (-webkit-min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) {
        .Modal.fullScreenWhiteModal .closeModal em {
          background-image: url(https://s.pinimg.com/webapp/style/images/webapp-common-desktop-2x-0d02cd03.png);
          background-position: -88px -375px;
          background-size: 428px 427px; } }
.Modal.fullScreenWhiteModal .closeModal:hover em,
    .Modal.fullScreenWhiteModal .closeModal:active em,
    .Modal.fullScreenWhiteModal .closeModal:focus em {
      width: 17px;
      height: 16px;
      background: url(https://s.pinimg.com/webapp/style/images/webapp-common-desktop-1x-28441dec.png) -339px -342px no-repeat; }
@media (-webkit-min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) {
        .Modal.fullScreenWhiteModal .closeModal:hover em,
        .Modal.fullScreenWhiteModal .closeModal:active em,
        .Modal.fullScreenWhiteModal .closeModal:focus em {
          background-image: url(https://s.pinimg.com/webapp/style/images/webapp-common-desktop-2x-0d02cd03.png);
          background-position: -70px -375px;
          background-size: 428px 427px; } }
.Modal.confirmDialogModal {
    z-index: 1001; }
/* desktop.scss */
.Modal .modalMask,
.Modal.webNewContentNewRepin .modalMask,
.ReactModal__Overlay {
  background-color: rgba(0, 0, 0, 0.6);
  opacity: 1; }
.Modal.flashlightModal .modalMask {
  background: #fff; }
.Modal .modalContent,
.Modal.webNewContentNewRepin .modalContent {
  border-radius: 8px;
  box-shadow: none; }
.Modal .formFooter,
.ReactModal__Content .formFooter {
  background: #fff; }
.Modal.fullScreenWhiteModal .modalMask {
  background: #fff; }
.ModuleCycler .navigation {
  opacity: 0;
  position: absolute;
  -webkit-transition: opacity .5s ease-in-out;
  transition: opacity .5s ease-in-out;
  width: 236px;
  z-index: 101; }
.ModuleCycler .navigation .navigator {
    position: absolute; }
.ModuleCycler .navigation .navigator em {
      cursor: pointer;
      display: inline-block;
      margin-top: -24px; }
.ModuleCycler .navigation .navigator.disabled {
      display: none; }
.ModuleCycler .navigation .navigator.leftArrow {
      left: 0; }
.ModuleCycler .navigation .navigator.left


lng,"cityId":"","fromPage":"ut-coupon-center/views/index/index","xAxes":"","yAxes":""},"content-type":"application/json","Didi-Ticket":token,"ptf":"mp","city_id":33,"platform":"mp","x_test_user":{"key":281475120025923}}},{"dchn":"gL3E8qZ","prod_key":"ut-support-coupon","runtime_args":{"token":token,"lat":lat,"lng":lng,"env":{"dchn":"wE7poOA","newTicket":token,"model":"2201122C","fromChannel":"2","newAppid":"35009","openId":"","openIdType":"1","sceneId":"1089","isHitButton":False,"isOpenWeb":False,"timeCost":70666,"latitude":lat,"longitude":lng,"cityId":"","fromPage":"ut-coupon-center/views/index/index","xAxes":"","yAxes":""},"content-type":"application/json","Didi-Ticket":token,"ptf":"mp","city_id":33,"platform":"mp","x_test_user":{"key": 281475120025923}}}]}
    tijiao = requests.post(url="https://api.didi.cn/webx/chapter/page/batch/config", json=data, headers=headers).json()
    if tijiao['errmsg'] == 'success':
        for xuju in tijiao['data']['conf'][0]['strategy_data']['data']['seckill']:
            for xu in xuju['coupons']:
                activity_id = xu['activity_id']
                group_id = xu['group_id']
                group_date = xu['group_date']
                coupon_conf_id = xu['coupon_conf_id']
                data = {"lang":"zh-CN","token":token,"access_key_id":9,"appversion":appversion,"channel":1100000002,"_ds":"","xpsid":"d51af08a62ef4b43b1eb41deaae30379","xpsid_root":"0fa1ac9f38d24e43a4a2616319942c88","activity_id":activity_id,"group_id":group_id,"group_date":group_date,"coupon_conf_id":coupon_conf_id,"dchn":"wE7poOA","platform":"mp","city_id":33,"env":{"isHitButton":True,"newAppid":35009,"userAgent":"","openId":"","model":"2201122C","wifi":2,"timeCost":""}}
                ju = requests.post(url="https://ut.xiaojukeji.com/ut/janitor/api/action/coupon/bind", json=data, headers=headers).json()

                if ju['errmsg'] == 'success':
                    myprint(f"{xu['name']}（{xu['threshold_desc']}）：{ju['errmsg']}")
                elif ju['errmsg'] == '领券失败请重试':
                    pass
                else:
                    print(f"{xu['name']}（{xu['threshold_desc']}）：{ju['errmsg']}")
                time.sleep(1)
    myprint('------------------')

def guafen(uid,token):
    myprint('--------瓜瓜乐打卡--------')
    headers = {'didi-ticket': token,'content-type':'application/json'}
    """
    #没用的
    data = {
    'lang' : 'zh-CN',
    'token' : token,
    'access_key_id' : 9,
    'appversion' : appversion,
    'channel' : 1100000002,
    '_ds' : '',


#define	HDLC
/*
 * VPM interpreter
 *
 * This version of the interpreter supports both BISYNC and HDLC.
 *
 * The desired protocol class is selected by the #define at line 1.
 *
 * Allocation of scratch-pad registers:
 *
 *	r15 - unused
 *	r14 - interpreter flags
 *	r13 - current state of the dialog with the PDP-11
 *	r12 - current state of the virtual process
 *	r11 - frame pointer (not used in phase 1)
 *	r10 - stack pointer
 *	 r9 - high-order bits of program counter (PC)
 *	 r8 - low-order bits of program counter (PC)
 *	 r7 - unused
 *	 r6 - accumulator (AC)
 *	 r5 - scratch
 *	 r4 - scratch
 *	 r3 - scratch
 *	 r2 - scratch
 *	 r1 - scratch
 *	 r0 - scratch
 *
 * Macro to delay until the previously requested unibus transfer,
 * if any, completes
 *
 * Usage:	BUSWAIT(label)
 *
 * where <label> is the address to receive control if a unibus
 * error occurs
 */
#define BUSWAIT(X)\
0:\
	mov	npr,brg;\
	br0	0b;\
	mov	nprx,brg;\
	br0	X;

/*
 * Macro to remove the xbt entry or rbt entry from the head
 * of a specified queue
 *
 * Usage:	REMOVEQ(queue,reg,Z);
 *
 * where <queue> is the name of the queue (the label for
 * the pointer to the head of the queue),
 * <reg> is the scratch-pad register to receive
 * the entry address, and <error> is the label to
 * receive control if the queue is empty
 *
 * Note:  This macro uses r0 as a scratch register.
 */
#define	REMOVEQ(X,Y,Z)\
	mov	X,mar;\
	mov	%X,%mar;\
	mov	mem,Y;\
	brz	Z;\
	mov	LINK,brg;\
	add	brg,Y,mar;\
	mov	mem,r0;\
	mov	X,mar;\
	mov	r0,mem|mar++;\
	brz	0f;\
	br	9f;\
0:\
	mov	r0,mem;\
9:

/*
 * Macro to append an xbt entry or an rbt entry to the end
 * of a specified queue
 *
 * Note:  This macro uses r0 as a scratch register and uses numeric label 9
 *	   as a forward-branch label
 */
#define	APPENDQ(X,Y)\
	mov	%xbt,%mar;\
	mov	LINK,brg;\
	add	brg,Y,mar;\
	mov	NIL,mem;\
	mov	X+1,mar;\
	mov	mem,r0;\
	brz	0f;\
	mov	Y,mem;\
	add	brg,r0,mar;\
	br	9f;\
0:\
	mov	X,mar;\
	mov	Y,mem|mar++;\
9:\
	mov	Y,mem

/*
 * Subroutine CALL and RETURN macros
 *
 * Nested calls are not supported
 */
#define	SCALL(X)\
	mov	%return,%mar;\
	mov	return,mar;\
	mov	%0f,mem|mar++;\
	mov	0f,mem;\
	mov	%X,brg;\
	mov	brg,pcr;\
	jmp	X;\
0:

#define	SRETURN	\
	mov	%return,%mar;\
	mov	return,mar;\
	mov	mem,pcr|mar++;\
	jmp	(mem)

/*
 * Define the number of transmit and receive buffers
 */
#define	NXB	4
#define	NRB	4
/*
 * Define command cod


lectionOwnerID := resp.Collection.Owner.ID
	filesOwnerID := userID
	// Verify that the user owns each file
	fileIDs := make([]int64, 0)
	for _, file := range files {
		fileIDs = append(fileIDs, file.ID)
	}
	err = c.AccessCtrl.VerifyFileOwnership(ctx, &access.VerifyFileOwnershipParams{
		ActorUserId: userID,
		FileIDs:     fileIDs,
	})

	if err != nil {
		return stacktrace.Propagate(err, "Failed to verify fileOwnership")
	}
	err = c.CollectionRepo.AddFiles(cID, collectionOwnerID, files, filesOwnerID)
	if err != nil {
		return stacktrace.Propagate(err, "")
	}
	return nil
}

// RestoreFiles restore files from trash and add to the collection
func (c *CollectionController) RestoreFiles(ctx *gin.Context, userID int64, cID int64, files []ente.CollectionFileItem) error {
	_, err := c.AccessCtrl.GetCollection(ctx, &access.GetCollectionParams{
		CollectionID:   cID,
		ActorUserID:    userID,
		IncludeDeleted: false,
		VerifyOwner:    true,
	})
	if err != nil {
		return stacktrace.Propagate(err, "failed to verify collection access")
	}
	// Verify that the user owns each file
	for _, file := range files {
		// todo #perf find owners of all files
		ownerID, err := c.FileRepo.GetOwnerID(file.ID)
		if err != nil {
			return stacktrace.Propagate(err, "")
		}
		if ownerID != userID {
			log.WithFields(log.Fields{
				"file_id":  file.ID,
				"owner_id": ownerID,
				"user_id":  userID,
			}).Error("invalid ops: can't add file which isn't owned by user")
			return stacktrace.Propagate(ente.ErrPermissionDenied, "")
		}
	}
	err = c.CollectionRepo.RestoreFiles(ctx, userID, cID, files)
	if err != nil {
		return stacktrace.Propagate(err, "")
	}
	return nil
}

// MoveFiles from one collection to another collection. Both the collections and files should belong to
// single user
func (c *CollectionController) MoveFiles(ctx *gin.Context, req ente.MoveFilesRequest) error {
	userID := auth.GetUserID(ctx.Request.Header)
	_, err := c.AccessCtrl.GetCollection(ctx, &access.GetCollectionParams{
		CollectionID:   req.FromCollectionID,
		ActorUserID:    userID,
		IncludeDeleted: false,
		VerifyOwner:    true,
	})
	if err != nil {
		return stacktrace.Propagate(err, "failed to verify if actor owns fromCollection")
	}

	_, err = c.AccessCtrl.GetCollection(ctx, &access.GetCollectionParams{
		CollectionID:   req.ToCollectionID,
		ActorUserID:    userID,
		IncludeDeleted: false,
		VerifyOwner:    true,
	})
	if err != nil {
		return stacktrace.Propagate(err, "failed to verify if actor owns toCollection")
	}

	// Verify that the user owns each file
	fileIDs := make([]int64, 0)
	for _, file := range req.Files {
		fileIDs = append(fileIDs, file.ID)
	}
	err = c.AccessCtrl.VerifyFileOwnership(ctx, &access.VerifyFileOwnershipParams{
		ActorUserId: userID,
		FileIDs:     fileIDs,
	})
	if err != nil {
		stacktrace.Propagate(err, "Failed to verify fileOwnership")
	}
	err = c.CollectionRepo.MoveFiles(ctx, req.ToCollectionID, req.FromCollectionID, req.Files, userID, userID)
	return stacktrace.Propagate


 our scroll position
					pixelsBelowScrollbar = pixelsBelowScrollbar + currentRowY
					if scrollPosition <= rowSize then
						scrollPosition = 1
						break
					else
						scrollPosition = scrollPosition - rowSize
					end
					currentRowY = 0
				else
					break
				end
			end

			if guiObjects[pos].AbsoluteSize.Y > currentRowY then
				currentRowY = guiObjects[pos].AbsoluteSize.Y
			end

			pos = pos - 1
		end

		--Do check last time if pos = 0
		if (pos == 0) and (pixelsBelowScrollbar + currentRowY <= totalPixelsY) then
			scrollPosition = 1
		end

		xCounter = 0
		--pos = scrollPosition
		rowSizeCounter = 0
		setRowSize = true
		local lastChildSize = 0

		local xOffset,yOffset = 0
		if guiObjects[1] then
			yOffset = math.ceil(math.floor(math.fmod(totalPixelsY,guiObjects[1].AbsoluteSize.X))/2)
			xOffset = math.ceil(math.floor(math.fmod(totalPixelsX,guiObjects[1].AbsoluteSize.Y))/2)
		end

		for i, child in ipairs(guiObjects) do
			if i < scrollPosition then
				--print("Hiding " .. child.Name)
				child.Visible = false
			else
				if pixelsRemainingY < 0 then
					--print("Out of Space " .. child.Name)
					child.Visible = false
				else
					--print("Laying out " .. child.Name)
					--GuiObject
					if setRowSize then rowSizeCounter = rowSizeCounter + 1 end
					if xCounter + child.AbsoluteSize.X >= totalPixelsX then
						if setRowSize then
							rowSize = rowSizeCounter - 1
							setRowSize = false
						end
						xCounter = 0
						pixelsRemainingY = pixelsRemainingY - child.AbsoluteSize.Y
					end
					child.Position = UDim2.new(child.Position.X.Scale,xCounter + xOffset, 0, totalPixelsY - pixelsRemainingY + yOffset)
					xCounter = xCounter + child.AbsoluteSize.X
					child.Visible = ((pixelsRemainingY - child.AbsoluteSize.Y) >= 0)
					if child.Visible then
						howManyDisplayed = howManyDisplayed + 1
					end
					lastChildSize = child.AbsoluteSize
				end
			end
		end

		scrollUpButton.Active = (scrollPosition > 1)
		if lastChildSize == 0 then
			scrollDownButton.Active = false
		else
			scrollDownButton.Active = ((pixelsRemainingY - lastChildSize.Y) < 0)
		end
		scrollDrag.Active = #guiObjects > howManyDisplayed
		scrollDrag.Visible = scrollDrag.Active
	end

	local layoutSimpleScrollBar = function()
		local guiObjects = {}
		howManyDisplayed = 0

		if orderList then
			for i, child in ipairs(orderList) do
				if child.Parent == frame then
					table.insert(guiObjects, child)
				end
			end
		else
			local children = frame:GetChildren()
			if children then
				for i, child in ipairs(children) do
					if child:IsA("GuiObject") then
						table.insert(guiObjects, child)
					end
				end
			end
		end
		if #guiObjects == 0 then
			scrollUpButton.Active = false
			scrollDownButton.Active = false
			scrollDrag.Active = false
			scrollPosition = 1
			return
		end

		if scrollPosition > #guiObjects then
			scrollPosition = #guiObjects
		end

		local totalPixels = frame.AbsoluteSize.Y
		local pixelsRemaining = frame.AbsoluteSize.Y

		local pixelsBelowScrollbar = 0
		local pos = #guiObjects
		while pixelsBelowScrollbar < totalPixels and pos >= 1 do
			if pos >= scrollPosition then
				pixelsBelowScrollbar = pixelsBelowScrollbar + guiObjects[pos].AbsoluteSize.Y
			else
				if


\\D\\C[BYBWCUETGSJRNPZO^N` RVDUFTJRVQZP]O_MaKbIbHaH`I_J`Ia",
  2269:" 50F^[CZD[E\\D\\C[BYBWCUETGSJRNPZO^N` RVDUFTJRVQZP]O_MaKbIbHaH`I_J`Ia RQKNLLNKQKSLVNXQYSYVXXVYSYQXNVLSKQK",
  2270:" 26F_\\S[UYVWVUUTTQPPONNLNJOIQISJULVNVPUQTTPUOWNYN[O\\Q\\S",
  2271:" 32F^[FI[ RNFPHPJOLMMKMIKIIJGLFNFPGSHVHYG[F RWTUUTWTYV[X[ZZ[X[VYTWT",
  2272:" 49F_[NZO[P\\O\\N[MZMYNXPVUTXRZP[M[JZIXIUJSPORMSKSIRGPFNGMIMKNNPQUXWZZ[[[\\Z\\Y RM[KZJXJUKSMQ RMKNMVXXZZ[",
  2273:" 56E`WNVLTKQKOLNMMPMSNUPVSVUUVS RQKOMNPNSOUPV RWKVSVUXVZV\\T]Q]O\\L[JYHWGTFQFNGLHJJILHOHRIUJWLYNZQ[T[WZYYZX RXKWSWUXV",
  2274:" 42H\\PBP_ RTBT_ RXIWJXKYJYIWGTFPFMGKIKKLMMNOOUQWRYT RKKMMONUPWQXRYTYXWZT[P[MZKXKWLVMWLX",
  2275:" 12H]SFLb RYFRb RLQZQ RKWYW",
  2276:" 46JZUITJUKVJVIUGSFQFOGNINKOMQOVR ROMTPVRWTWVVXTZ RPNNPMRMTNVPXU[ RNVSYU[V]V_UaSbQbOaN_N^O]P^O_",
  2277:" 30JZRFQHRJSHRF RRFRb RRQQTRbSTRQ RLMNNPMNLLM RLMXM RTMVNXMVLTM",
  2278:" 56JZRFQHRJSHRF RRFRT RRPQRSVRXQVSRRP RRTRb RR^Q`RbS`R^ RLMNNPMNLLM RLMXM RTMVNXMVLTM RL[N\\P[NZL[ RL[X[ RT[V\\X[VZT[",
  2279:" 12I\\XFX[ RKFXF RPPXP RK[X[",
  2281:" 38E`QFNGKIILHOHRIUKXNZQ[T[WZZX\\U]R]O\\LZIWGTFQF RROQPQQRRSRTQTPSORO RRPRQSQSPRP",
  2282:" 45J[PFNGOIQJ RPFOGOI RUFWGVITJ RUFVGVI RQJOKNLMNMQNSOTQUTUVTWSXQXNWLVKTJQJ RRUR[ RSUS[ RNXWX",
  2283:" 27I\\RFOGMILLLMMPORRSSSVRXPYMYLXIVGSFRF RRSR[ RSSS[ RNWWW",
  2284:" 28D`PFMGJIHLGOGSHVJYM[P\\T\\W[ZY\\V]S]O\\LZIWGTFPF RRFR\\ RGQ]Q",
  2285:" 31G`PMMNKPJSJTKWMYPZQZTYVWWTWSVPTNQMPM R]GWG[HUN R]G]M\\IVO R\\HVN",
  2286:" 28F\\IIJGLFOFQGRIRLQOPQNSKU ROFPGQIQMPPNS RVFT[ RWFS[ RKUYU",
  2287:" 30I\\MFMU RNFMQ RMQNOON


scriptIndex; i >= 0; i--) {
          final checkNode = _script.children[i];
          if (checkNode is LabelNode) {
            currentLabel = checkNode.name;
            break;
          }
        }

        // 更新智能预热
        _smartPredictor.smartPreWarm(
          scriptNodes: _script.children,
          currentIndex: _scriptIndex,
          currentLabel: currentLabel,
        );
      }

      // 跳过注释节点（文件边界标记）
      if (node is CommentNode) {
        if (kDebugMode) {
          //////print('[GameManager] 跳过注释: ${node.comment}');
        }
        _scriptIndex++;
        continue;
      }

      // 跳过标签节点
      if (node is LabelNode) {
        // 通知章节自动存档管理器：经过了一个label
        _chapterAutoSaveManager.onLabelPassed(node.name);

        _scriptIndex++;
        continue;
      }

      if (node is BackgroundNode) {
        // 检查当前scene是否是章节末尾前最后一个没有对话的scene
        await _checkChapterEndAutoSave(_scriptIndex);

        // 检查是否要清空CG状态
        // 如果新背景不是CG且当前有CG显示，则清空CG
        final isNewBackgroundCG = node.background.toLowerCase().contains('cg');
        final shouldClearCG =
            !isNewBackgroundCG && _currentState.cgCharacters.isNotEmpty;

        if (shouldClearCG) {
          ////print('[GameManager] 切换到非CG背景，清空CG状态');
        }

        // 检查下一个节点是否是FxNode，如果是则一起处理
        SceneFilter? sceneFilter;
        int nextIndex = _scriptIndex + 1;
        if (nextIndex < _script.children.length &&
            _script.children[nextIndex] is FxNode) {
          final fxNode = _script.children[nextIndex] as FxNode;
          sceneFilter = SceneFilter.fromString(fxNode.filterString);
        }

        // 检查是否是游戏开始时的初始背景设置
        final isInitialBackground = _currentState.background == null &&
            _currentState.cgCharacters.isEmpty;
        final isSameBackground = _currentState.background == node.background;
        // 检查是否从CG切换到场景，如果是则强制使用转场效果
        final isFromCGToScene = _currentState.cgCharacters.isNotEmpty &&
            !node.background.toLowerCase().contains('cg');

        // 快进模式下跳过转场效果，或其他需要跳过转场的情况
        // 但从CG切换到场景时必须使用转场效果
        if ((_isFastForwardMode ||
                _context == null ||
                isInitialBackground ||
                isSameBackground) &&
            !isFromCGToScene) {
          ////print('[GameManager] 跳过转场：${_isFastForwardMode ? "快进模式" : (isInitialBackground ? "初始背景" : (isSameBackground ? "相同背景" : "无context"))}');
          // 直接切换背景
          _currentState = _currentState.copyWith(
              background: node.background,
              movieFile: null, // 新增：scene命令清


 matching the given property values.
 */
function explodeSGFList(propValues) {
  var coords = [];

  for(var i=0, len=propValues.length; i<len; i++) {
    var val = propValues[i];

    if(val.indexOf(':') == -1) { // single coordinate
      coords.push(new Coordinate(val));
    } else {
      var tuple = val.split(':'), c1, c2, coord;

      c1 = new Coordinate(tuple[0]);
      c2 = new Coordinate(tuple[1]);
      coord = new Coordinate();

      for(coord.i=c1.i; coord.i<=c2.i; ++coord.i)
        for(coord.j=c1.j; coord.j<=c2.j; ++coord.j)
          coords.push(coord.copy());
    }
  }

  return coords;
}

function sgfMove(node, name, values, moveMarks) {
  var coord, player, opponent, play;

  if(name == 'B') {
    player = C.BLACK;
    opponent = C.WHITE;
  } else if('W') {
    player = C.WHITE;
    opponent = C.BLACK;
  }

  coord = (values[0].length == 2) ? new Coordinate(values[0]) : null;

  // Apparently, IGS wants to use outside-board coordinates for pass
  if(coord !== null && (coord.i >= node.jboard.width || coord.j >= node.jboard.height))
    coord = null; // Thank you, IGS

  play = node.jboard.playMove(coord, player);
  node.info.captures[player] += play.captures.length; // tally captures

  if(moveMarks && play.ko)
      node.setMark(play.ko, C.MARK.SQUARE);

  if(play.success && coord !== null) {
    node.setType(coord, player); // play stone
    node.setType(play.captures, C.CLEAR); // clear opponent's stones
    if(moveMarks)
      node.setMark(coord, C.MARK.CIRCLE);
  } else ERROR = play.error;

  return play.success;
}

function sgfSetup(node, name, values) {
  var setupMap = {'AB': C.BLACK, 'AW': C.WHITE, 'AE': C.CLEAR};

  node.setType(explodeSGFList(values), setupMap[name]);
  return true;
}

function sgfMarker(node, name, values) {
  var markerMap = {
    'TW': C.MARK.WHITE_TERRITORY,
    'TB': C.MARK.BLACK_TERRITORY,
    'CR': C.MARK.CIRCLE,
    'TR': C.MARK.TRIANGLE,
    'MA': C.MARK.CROSS,
    'SQ': C.MARK.SQUARE
  };

  node.setMark(explodeSGFList(values), markerMap[name]);
  return true;
}

function sgfComment(node, name, values) {
  node.info.comment = values[0];
  return true;
}

function sgfHandicap(node, name, values) {
  node.info.handicap = values[0];
  return true;
}

function sgfLabel(node, name, values) {
  for(var i=0; i<values.length; i++) {
    var v = values[i], tuple = v.split(':');

    node.setMark(new Coordinate(tuple[0]), tuple[1]);
  }
  return true;
}

function sgfInfo(node, name, values) {
  var field = fieldMap[name];

  node.info[field] = values[0];
  return true;
}

var SGFProperties = {
  'B': sgfMove,
  'W': sgfMove,
  'AB': sgfSetup,
  'AW': sgfSetup,
  'AE': sgfSetup,
  'C': sgfComment,
  'LB': sgfLabel,
  'HA': sgfHandicap,
  'TW': sgfMarker,
  'TB': sgfMarker,
  'CR


 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

using System.Collections.Generic;

namespace VirtualRadar.Plugin.Vatsim.VatsimApiModels
{
    class VatsimDataV3
    {
        public VatsimDataV3General general { get; } = new VatsimDataV3General();

        public List<VatsimDataV3Pilot> pilots { get; } = new List<VatsimDataV3Pilot>();

        public List<VatsimDataV3Controller> controllers { get; } = new List<VatsimDataV3Controller>();

        public List<VatsimDataV3Atis> atis { get; } = new List<VatsimDataV3Atis>();

        public List<VatsimDataV3Server> servers { get; } = new List<VatsimDataV3Server>();

        public List<VatsimDataV3Prefile> prefiles { get; } = new List<VatsimDataV3Prefile>();

        public List<VatsimDataV3Facility> facilities { get; } = new List<VatsimDataV3Facility>();

        public List<VatsimDataV3Rating> ratings { get; } = new List<VatsimDataV3Rating>();

        public List<VatsimDataV3PilotRating> pilot_ratings { get; } = new List<VatsimDataV3PilotRating>();
    }
}


n License".
  </p>
 </body>
</html>
<html>
 <head>
  <title>
   中共福建省委召开会议研究知识分子等问题 - 1956-1-10 - CCRD 中国当代政治运动史数据库
  </title>
  <link href="../../../../Emblem_of_the_PCP-Shining_Path.svg.ico" rel="icon" type="image/x-icon"/>
 </head>
 <body>
  <meta content="中共福建省委召开会议研究知识分子等问题" property="title"/>
  <meta content="1956-1-10" property="date"/>
  <meta content="" property="authors"/>
  <script type="application/ld+json">
   {"title": "\u4e2d\u5171\u798f\u5efa\u7701\u59d4\u53ec\u5f00\u4f1a\u8bae\u7814\u7a76\u77e5\u8bc6\u5206\u5b50\u7b49\u95ee\u9898", "date": "1956-1-10", "authors": [], "contents": [{"text": "\u4e2d\u5171\u798f\u5efa\u7701\u59d4\u53ec\u5f00\u4f1a\u8bae\u7814\u7a76\u77e5\u8bc6\u5206\u5b50\u7b49\u95ee\u9898", "type": "title"}, {"text": "\u3010\u798f\u5efa\u5206\u793e10\u65e5\u8baf\u3011\u4e2d\u5171\u798f\u5efa\u7701\u59d4\u57281956\u5e74\u65b0\u5e74\u524d\u540e\u53ec\u5f00\u7684\u6269\u5927\u5e72\u90e8\u4f1a\u8bae\u4e0a\uff0c\u7814\u7a76\u4e86\u5173\u65bc\u52a0\u5f3a\u56e2\u7ed3\u3001\u6539\u9020\u77e5\u8bc6\u5206\u5b50\u7684\u5de5\u4f5c\u3002", "type": "paragraph"}, {"text": "\u798f\u5efa\u7701\u5bf9\u77e5\u8bc6\u5206\u5b50\u7684\u5de5\u4f5c\u57fa\u672c\u4e0a\u662f\u597d\u7684\uff0c\u76ee\u524d\u5728\u77e5\u8bc6\u5206\u5b50\u4e2d\u95f4\u76f8\u4fe1\u5171\u4ea7\u515a\uff0c\u62e5\u62a4\u793e\


Minnesota Avenue NE/SE

Monday-Saturday service only.

Fare: $1 (south of Good Hope Road & Minnesota Av SE, unless transferring to another bus)

Saturday service began in late 2011

U4
Sheriff Road-River Terrace Line
Local

River Terrace and Mayfair

Minnesota Avenue station

Sheriff Road NE

Minnesota Avenue NE

Benning Road NE

order of terminals (north to south): River Terrace to Minnesota Avenue then Minnesota Avenue to Sheriff Road NE, then reverse.

Formerly known as the M16 (Metro "Mini-Bus")

U5, U6
Mayfair-Marshall Heights Line
Local

U5, U6 Marshall Heights

U6 Mayfair

Minnesota Avenue station

Minnesota Avenue NE/SE

Texas Avenue SE

U6: order of terminals: Marshall Heights to Minnesota Avenue then Minnesota Avenue to Mayfair, then reverse.

Runs on a portion of the old M16 (Metro "Mini-Bus")

U8
Capitol Heights-Benning Heights Line
Local

Capitol Heights station and Benning Heights (H St & 45th Place SE)

Minnesota Avenue station

<td


# observer.py

class Observer:
    def update(self, data):
        """Receive update from subject"""
        pass

class Subject:
    def __init__(self):
        self._observers = []

    def attach(self, observer):
        """Attach an observer"""
        self._observers.append(observer)

    def detach(self, observer):
        """Detach an observer"""
        self._observers.remove(observer)

    def notify(self, data):
        """Notify all observers"""
        for observer in self._observers:
            observer.update(data)

# observer.py (continue from above)

class LoggingObserver(Observer):
    def update(self, data):
        """Log classification updates"""
        print(f"LoggingObserver: Received update - {data}")
# Copyright (c) 2024 David Adediji
# Licensed under the MIT License. See the LICENSE file for details.


/*!
(c) 2011-2013 Forers, s. r. o.: telxcc
*/

#ifndef teletext_h_included
#define teletext_h_included

//#include <inttypes.h>

#define MAX_TLT_PAGES 1000

typedef struct {
	uint64_t show_timestamp; // show at timestamp (in ms)
	uint64_t hide_timestamp; // hide at timestamp (in ms)
	uint16_t text[25][40]; // 25 lines x 40 cols (1 screen/page) of wide chars
	uint8_t g2_char_present[25][40]; // 0- Supplementary G2 character set NOT used at this position 1-Supplementary G2 character set used at this position
	uint8_t tainted; // 1 = text variable contains any data
} teletext_page_t;

// application states -- flags for notices that should be printed only once
struct s_states {
	uint8_t programme_info_processed;
	uint8_t pts_initialized;
};

typedef enum
{
	TRANSMISSION_MODE_PARALLEL = 0,
	TRANSMISSION_MODE_SERIAL = 1
} transmission_mode_t;

typedef enum
{
	DATA_UNIT_EBU_TELETEXT_NONSUBTITLE = 0x02,
	DATA_UNIT_EBU_TELETEXT_SUBTITLE = 0x03,
	DATA_UNIT_EBU_TELETEXT_INVERTED = 0x0c,
	DATA_UNIT_VPS = 0xc3,
	DATA_UNIT_CLOSED_CAPTIONS = 0xc5
} data_unit_t;

struct TeletextCtx
{
	short int seen_sub_page[MAX_TLT_PAGES];
	uint8_t verbose : 1; // should telxcc be verbose?
	uint16_t page; // teletext page containing cc we want to filter
	uint16_t tid; // 13-bit packet ID for teletext stream
	double offset; // time offset in seconds
	uint8_t bom : 1; // print UTF-8 BOM characters at the beginning of output
	uint8_t nonempty : 1; // produce at least one (dummy) frame
						  // uint8_t se_mode : 1; // search engine compatible mode => Uses CCExtractor's write_format
						  // uint64_t utc_refvalue; // UTC referential value => Moved to ccx_decoders_common, so can be used for other decoders (608/xds) too
	uint16_t user_page; // Page selected by user, which MIGHT be different to 'page' depending on autodetection stuff
	int levdistmincnt, levdistmaxpct; // Means 2 fails or less is "the same", 10% or less is also "the same"
	struct ccx_boundary_time extraction_start, extraction_end; // Segment we actually process
	enum ccx_output_format write_format; // 0=Raw, 1=srt, 2=SMI
	int gui_mode_reports; // If 1, output in stderr progress updates so the GUI can grab them
	enum ccx_output_date_format date_format;
	int noautotimeref; // Do NOT set time automatically?
	unsigned send_to_srv;
	char millis_separator;
	uint32_t global_timestamp;

	// Current and previous page buffers. This is the output written to file when
	// the time comes.
	teletext_page_t page_buffer;
	char *page_buffer_prev;
	char *page_buffer_cur;
	unsigned page_buffer_cur_size;
	unsigned page_buffer_cur_used;
	unsigned page_buffer_prev_size;
	unsigned page_buffer_prev_used;
	// Current and previous page compare strings. This is plain text (no colors,
	// tags, etc) in UCS2 (fixed length), so we can compare easily.
	uint64_t *ucs2_buffer_prev;
	uint64_t *ucs2_buffer_cur;
	unsigned ucs2_buffer_cur_size;
	unsigned ucs2_buffer_cur_used;
	unsigned ucs2_buffer_prev_size;
	unsigned ucs2_buffer_prev_used;
	// Buffer timestamp
	uint64_t prev_hide_timestamp;
	uint64_t prev_show_timestamp;
	// subtitle type pages bitmap, 2048 bits = 2048 possible pages in teletext (excl. subpages)
	uint8_t cc_map[256];
	// last timestamp computed
	uint64_t last_timestamp;
	struct s_states states;
	// FYI, packet counter
	uint32_t tlt_packet_counter;
	// teletext transmission mode
	transmission_mode_t transmission_mode;
	// flag indicating if incoming data should be processed or ignored
	uint8_t receiving_data;

	uint8_t using_pts;
	int64_t delta;
	uint32_t t0;

	int sentence_cap;//Set to 1 if -sc is passed
	int new_sentence;
	int splitbysentence;
};

int tlt_print_seen_pages(struct lib_cc_decode *dec_ctx);
void telxcc_dump_prev_page(struct TeletextCtx *ctx, struct cc_subtitle *sub);
void set_tlt_delta(struct lib_cc_decode *dec_ctx, uint64_t pts);
#endif


Type
	(TransportEvent_Event_DeviceChange_Type)(0), // 1: WAArmadilloTransportEvent.TransportEvent.Event.DeviceChange.Type
	(TransportEvent_Placeholder_Type)(0),        // 2: WAArmadilloTransportEvent.TransportEvent.Placeholder.Type
	(*TransportEvent)(nil),                      // 3: WAArmadilloTransportEvent.TransportEvent
	(*TransportEvent_Event)(nil),                // 4: WAArmadilloTransportEvent.TransportEvent.Event
	(*TransportEvent_Placeholder)(nil),          // 5: WAArmadilloTransportEvent.TransportEvent.Placeholder
	(*TransportEvent_Event_IcdcAlert)(nil),      // 6: WAArmadilloTransportEvent.TransportEvent.Event.IcdcAlert
	(*TransportEvent_Event_DeviceChange)(nil),   // 7: WAArmadilloTransportEvent.TransportEvent.Event.DeviceChange
}
var file_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto_depIdxs = []int32{
	5, // 0: WAArmadilloTransportEvent.TransportEvent.placeholder:type_name -> WAArmadilloTransportEvent.TransportEvent.Placeholder
	4, // 1: WAArmadilloTransportEvent.TransportEvent.event:type_name -> WAArmadilloTransportEvent.TransportEvent.Event
	7, // 2: WAArmadilloTransportEvent.TransportEvent.Event.deviceChange:type_name -> WAArmadilloTransportEvent.TransportEvent.Event.DeviceChange
	6, // 3: WAArmadilloTransportEvent.TransportEvent.Event.icdcAlert:type_name -> WAArmadilloTransportEvent.TransportEvent.Event.IcdcAlert
	2, // 4: WAArmadilloTransportEvent.TransportEvent.Placeholder.type:type_name -> WAArmadilloTransportEvent.TransportEvent.Placeholder.Type
	0, // 5: WAArmadilloTransportEvent.TransportEvent.Event.IcdcAlert.type:type_name -> WAArmadilloTransportEvent.TransportEvent.Event.IcdcAlert.Type
	1, // 6: WAArmadilloTransportEvent.TransportEvent.Event.DeviceChange.type:type_name -> WAArmadilloTransportEvent.TransportEvent.Event.DeviceChange.Type
	7, // [7:7] is the sub-list for method output_type
	7, // [7:7] is the sub-list for method input_type
	7, // [7:7] is the sub-list for extension type_name
	7, // [7:7] is the sub-list for extension extendee
	0, // [0:7] is the sub-list for field type_name
}

func init() { file_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto_init() }
func file_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto_init() {
	if File_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto != nil {
		return
	}
	file_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto_msgTypes[0].OneofWrappers = []any{
		(*TransportEvent_Placeholder_)(nil),
		(*TransportEvent_Event_)(nil),
	}
	file_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto_msgTypes[1].OneofWrappers = []any{
		(*TransportEvent_Event_DeviceChange_)(nil),
		(*TransportEvent_Event_IcdcAlert_)(nil),
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: file_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto_rawDesc,
			NumEnums:      3,
			NumMessages:   5,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_waArmadilloTransportEvent_WAArmadilloTransportEvent_proto_goTypes,
		DependencyIndexes: file_waArmadilloTr


leAttachments.Any()) return;
            foreach (var file in PageSetup.FileAttachments)
            {
                var fileInfo = new FileInfo(file.FilePath);
                var pdfDictionary = new PdfDictionary();
                pdfDictionary.Put(PdfName.MODDATE, new PdfDate(fileInfo.LastWriteTime));
                var fs = PdfFileSpecification.FileEmbedded(PdfWriter, file.FilePath, fileInfo.Name, null, true, null, pdfDictionary);
                PdfWriter.AddFileAttachment(file.Description, fs);
            }
        }

        /// <summary>
        /// Sets the PageSize and its background color.
        /// </summary>
        /// <returns>PageSize info</returns>
        public static Rectangle GetPageSizeAndColor(DocumentPreferences pageSetup)
        {
            var originalPageSize = pageSetup.PagePreferences.Orientation == PageOrientation.Landscape
                                            ? pageSetup.PagePreferences.Size.Rotate() : pageSetup.PagePreferences.Size;
            var notRotatedPageSize = new Rectangle(originalPageSize.Left, originalPageSize.Bottom, originalPageSize.Width, originalPageSize.Height);

            if (pageSetup.PagePreferences.PagesBackgroundColor != null)
                notRotatedPageSize.BackgroundColor = new BaseColor(pageSetup.PagePreferences.PagesBackgroundColor.Value.ToArgb());

            return notRotatedPageSize;
        }
    }
}


理失败
	 */
	DATACLEAN_ERROR("dataclean_error");

    private String value;

    private MigrateStatusEnum(String value) {
        this.value = value;
    }

    public String getValue() {
        return value;
    }

    public static MigrateStatusEnum getEnum(String value) {
        for (MigrateStatusEnum e : values()) {
            if (e.getValue().equals(value)) {
                return e;
            }
        }
        return null;
    }
}
package com.alibaba.doris.common;

/**
 * Data Server和Admin Server专用的节点状态 NodeStatus
 *
 * @since 1.0 2011-5-18
 */
public enum NodeStatus {

    /**
     * 正常状态
     */
    OK(1),

    /**
     * 临时失效，如发布、网络不稳定等情况下
     */
    TEMP_FAILED(2),

    /**
     * 临时失效恢复，从临时失效状态恢复正常
     */
    TEMP_FAILED_RESOLVE(3),

    /**
     * 永久失效，如机器故障等
     */
    FOROVER_FAILED(4),

    /**
     * 永久失效恢复，如备用机切换上去
     */
    FOROVER_FAILED_RESOLVE(5),

    /**
     * 迁移中
     */
    MIGRATING(6),

    /**
     * @deprecated
     */
    INCRE_MIGERATE_PREPARE(7),

    /**
     * @deprecated
     */
    INCRE_MIGERATE_START(8);

    private int value;

    private NodeStatus(int value) {
        this.value = value;
    }

    /** 返回常量字符串 */
    public int getValue() {
        return value;
    }

    /** 根据字符串得到Enum类型，区分大小写，如果没有匹配成功则返回null */
    public static NodeStatus getTypeByValue(int value) {
        for (NodeStatus type : values()) {
            if (type.getValue()== value) {
                return type;
            }
        }
        return null;
    }
}
/*
Copyright(C) 2010-2011 Alibaba Group Holding Limited
All rights reserved.

Licensed 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.alibaba.doris.common.migrate;

import java.util.HashMap;
import java.util.Map;

import com.alibaba.doris.common.MigrateTypeEnum;

/**
 * MigrateSubCommand
 * @author Kun He (Raymond He), kun.hek@alibaba-inc.com
 * @since 1.0 2011-5-27
 */
public enum MigrateSubCommand {

	/**
	 * migrate subcommand
	 */
	EXPANSION_START("expansion_start"),

	TEMP_FAILOVER_START("temp_failover_start"),

	FOREVER_FAILOVER_START("forever_failover_start"),

	/**
	 * mock 测试专用
	 */
	MOCK_MIGRATE_START("mock_migrate_start"),

	/**
	 * all_finished subcommand
	 */
	EXPANSION_ALL_FINISHED("expansion_all_finished"),

	TEMP_FAILOVER_ALL_FINISHED("temp_failover_all_finished"),

	FOREVER_FAILOVER_ALL_FINISHED("forever_failover_all_finished"),

	/**
	 * c


err	# make sure address is in user space
	nop
	GET_CPU_PCPU(v1)
	PTR_L	v1, PC_CURPCB(v1)
	PTR_S	v0, U_PCB_ONFAULT(v1)
	sb	a1, 0(a0)		# store byte
	PTR_S	zero, U_PCB_ONFAULT(v1)
	j	ra
	move	v0, zero
END(subyte)

LEAF(fswberr)
	j	ra
	li	v0, -1
END(fswberr)

/*
 * fuswintr and suswintr are just like fusword and susword except that if
 * the page is not in memory or would cause a trap, then we return an error.
 * The important thing is to prevent sleep() and switch().
 */
LEAF(fuswintr)
	PTR_LA	v0, fswintrberr
	blt	a0, zero, fswintrberr	# make sure address is in user space
	nop
	GET_CPU_PCPU(v1)
	PTR_L	v1, PC_CURPCB(v1)
	PTR_S	v0, U_PCB_ONFAULT(v1)
	lhu	v0, 0(a0)		# fetch short
	j	ra
	PTR_S	zero, U_PCB_ONFAULT(v1)
END(fuswintr)

LEAF(suswintr)
	PTR_LA	v0, fswintrberr
	blt	a0, zero, fswintrberr	# make sure address is in user space
	nop
	GET_CPU_PCPU(v1)
	PTR_L	v1, PC_CURPCB(v1)
	PTR_S	v0, U_PCB_ONFAULT(v1)
	sh	a1, 0(a0)		# store short
	PTR_S	zero, U_PCB_ONFAULT(v1)
	j	ra
	move	v0, zero
END(suswintr)

LEAF(fswintrberr)
	j	ra
	li	v0, -1
END(fswintrberr)

/*
 * memcpy(to, from, len)
 * {ov}bcopy(from, to, len)
 */
LEAF(memcpy)
	.set	noreorder
	move	v0, a0			# swap from and to
	move	a0, a1
	move	a1, v0
ALEAF(bcopy)
ALEAF(ovbcopy)
	.set	noreorder
	PTR_ADDU	t0, a0, a2		# t0 = end of s1 region
	sltu	t1, a1, t0
	sltu	t2, a0, a1
	and	t1, t1, t2		# t1 = true if from < to < (from+len)
	beq	t1, zero, forward	# non overlapping, do forward copy
	slt	t2, a2, 12		# check for small copy

	ble	a2, zero, 2f
	PTR_ADDU	t1, a1, a2		# t1 = end of to region
1:
	lb	v1, -1(t0)		# copy bytes backwards,
	PTR_SUBU	t0, t0, 1		#   doesnt happen often so do slow way
	PTR_SUBU	t1, t1, 1
	bne	t0, a0, 1b
	sb	v1, 0(t1)
2:
	j	ra
	nop
forward:
	bne	t2, zero, smallcpy	# do a small bcopy
	xor	v1, a0, a1		# compare low two bits of addresses
	and	v1, v1, 3
	PTR_SU


/*
* Farseer Physics Engine:
* Copyright (c) 2012 Ian Qvist
*/

using System;

namespace TrueSync.Physics2D
{
    [Flags]
    public enum DebugViewFlags
    {
        /// <summary>
        /// Draw shapes.
        /// </summary>
        Shape = (1 << 0),

        /// <summary>
        /// Draw joint connections.
        /// </summary>
        Joint = (1 << 1),

        /// <summary>
        /// Draw axis aligned bounding boxes.
        /// </summary>
        AABB = (1 << 2),

        /// <summary>
        /// Draw broad-phase pairs.
        /// </summary>
        //Pair = (1 << 3),

        /// <summary>
        /// Draw center of mass frame.
        /// </summary>
        CenterOfMass = (1 << 4),

        /// <summary>
        /// Draw useful debug data such as timings and number of bodies, joints, contacts and more.
        /// </summary>
        DebugPanel = (1 << 5),

        /// <summary>
        /// Draw contact points between colliding bodies.
        /// </summary>
        ContactPoints = (1 << 6),

        /// <summary>
        /// Draw contact normals. Need ContactPoints to be enabled first.
        /// </summary>
        ContactNormals = (1 << 7),

        /// <summary>
        /// Draws the vertices of polygons.
        /// </summary>
        PolygonPoints = (1 << 8),

        /// <summary>
        /// Draws the performance graph.
        /// </summary>
        PerformanceGraph = (1 << 9),

        /// <summary>
        /// Draws controllers.
        /// </summary>
        Controllers = (1 << 10)
    }

    /// Implement and register this class with a World to provide debug drawing of physics
    /// entities in your game.
    public abstract class DebugViewBase
    {
        protected DebugViewBase(World world)
        {
            World = world;
        }

        protected World World { get; private set; }

        /// <summary>
        /// Gets or sets the debug view flags.
        /// </summary>
        /// <value>The flags.</value>
        public DebugViewFlags Flags { get; set; }

        /// <summary>
        /// Append flags to the current flags.
        /// </summary>
        /// <param name="flags">The flags.</param>
        public void AppendFlags(DebugViewFlags flags)
        {
            Flags |= flags;
        }

        /// <summary>
        /// Remove flags from the current flags.
        /// </summary>
        /// <param name="flags">The flags.</param>
        public void RemoveFlags(DebugViewFlags flags)
        {
            Flags &= ~flags;
        }

        /// <summary>
        /// Draw a closed polygon provided in CCW order


gold']} {$_LANG['金币']}

          {/if}
        {/if}

			{if $forum[$thread_data['fid']]['fid'] != -1}

	            {php echo forum($forum,$forum[$thread_data['fid']]['fid'],'name');}

	        {/if}

	            {php echo forum($forum,$thread_data['fid'],'name');}

	{if $thread_data['files']}

{$_LANG['附件列表']}

		{foreach $filelist as $v}

	     {if $v['show']}

	        {$v.name}
	          {$_LANG['文件大小']}:{php echo round($v['size']/1024/1024,2);}M ({$_LANG['下载次数']}：{$v.downs})
	        {if $v['gold']}
	           {$_LANG['售价']}:{$v.gold}
	        {/if}

	      {else}

	        {$_LANG['附件隐藏提示']}

	     {/if}

	     {/foreach}

	{/if}

		{php $DataModel = M('Data');$User = M('User');}
		{php $floor=1;}
		{foreach $PostList as $k => $v}
		{if $v['rpid']}
        	{php $quote_data = $DataModel->get_post_data($v['rpid'])}
        {/if}


"""
Sherlock considers a string to be valid if all characters of the string appear
the same number of times. It is also valid if he can remove just 1 character at 1
index in the string, and the remaining characters will occur the same number of
times. Given a string s, determine if it is valid. If so, return YES, otherwise
return NO.

Constraints:

- 1 <= |s| <= 10^5
- each character s[i] belongs to ascii[a-z]
"""

#!/bin/python3

import math
import os
import random
import re
import sys
from string import ascii_lowercase

#
# Complete the 'isValid' function below.
#
# The function is expected to return a STRING.
# The function accepts STRING s as parameter.
#

# abcdefghhgfedecba
# mapping = {'a': 2, 'b': 2, 'c': 2, 'd': 2, 'e': 3, 'f': 2, 'g': 2, 'h': 2}
# num_diff_frequencies = [1, 2]
# sorted_count = [1, 2, 2]
# n = 8

def isValid(s):
    def all_equal(a: list[int]) -> bool:
        for i in range(1, len(a)):
            if a[i] != a[i-1]:
                return False
        return True

    mapping = {}
    for letter in s:
        if mapping.get(letter, None) is None:
            mapping[letter] = 1
        else:
            mapping[letter] += 1

    num_diff_frequencies = len(set(mapping.values()))
    if num_diff_frequencies == 1:
        # All characters appear the same number of times
        return 'YES'
    elif num_diff_frequencies > 2:
        # I have at least 3 letters with different num of frequencies
        # therefore I cannot substract just 1 of them and have 3
        # equal elements
        return 'NO'
    else:
        # num_diff_frequencies == 2
        # Only way for this to work is:
        # 1) if all frequencies count equal K and the only different number is K + 1
        # 2) if all frequencies count are K and the smallest frequency is 1 => we can remove
        # the only different value !
        sorted_count = sorted(mapping.values())
        n = len(sorted_count)
        if sorted_count[0] == 1 and all_equal(sorted_count[1:n]):
            return 'YES' # We delete this first char
        elif sorted_count[0] == sorted_count[n - 1] - 1 and all_equal(sorted_count[0:n-1]):
            return 'YES'
        else:
            return 'NO'

assert 'YES' == isValid("abc")

assert 'NO' == isValid("abccc")

assert 'YES' == isValid("abcdefghhgfedecba")

assert 'YES' == isValid("aabbc")

if __name__ == '__main__':
    fptr = open(os.environ['OUTPUT_PATH'], 'w')

    s = input()

    result = isValid(s)

    fptr.write(result + '\n')

    fptr.close()


return τ = tanφ
   *
   * See Eqs. (19--21) of
   * C. F. F. Karney,
   *
   * Transverse Mercator with an accuracy of a few nanometers,
   * J. Geodesy 85(8), 475--485 (Aug. 2011)
   * (preprint
   * arXiv:1002.1417).
   **********************************************************************/
  static double tauf(double taup, double es) {
    const int numit = 5;
    // min iterations = 1, max iterations = 2; mean = 1.95
    double tol = sqrt(practical_epsilon) / 10;
    double taumax = 2 / sqrt(practical_epsilon);
    double e2m = 1 - sq(es),
        // To lowest order in e^2, taup = (1 - e^2) * tau = _e2m * tau; so use
        // tau = taup/e2m as a starting guess. Only 1 iteration is needed for
        // |lat| < 3.35 deg, otherwise 2 iterations are needed.  If, instead, tau
        // = taup is used the mean number of iterations increases to 1.999 (2
        // iterations are needed except near tau = 0).
        //
        // For large tau, taup = exp(-es*atanh(es)) * tau.  Use this as for the
        // initial guess for |taup| > 70 (approx |phi| > 89deg).  Then for
        // sufficiently large tau (such that sqrt(1+tau^2) = |tau|), we can exit
        // with the intial guess and avoid overflow problems.  This also reduces
        // the mean number of iterations slightly from 1.963 to 1.954.
        tau = taup.abs() > 70 ? taup * exp(eatanhe(1.0, es)) : taup / e2m,
        stol = tol * max<double>(1.0, taup.abs());
    if (!(tau.abs() < taumax)) return tau; // handles +/-inf and nan
    for (int i = 0; i < numit || _GEOGRAPHICLIB_PANIC; ++i) {
      double taupa = taupf(tau, es),
          dtau = (taup - taupa) * (1 + e2m * sq(tau)) / (e2m * hypot(1.0, tau) * hypot(1.0, taupa));
      tau += dtau;
      if (!(dtau.abs() >= stol)) {
        break;
      }
    }
    return tau;
  }
}
/*
    Dart port of C++ implementation of
    ======================
    GeographicLib
    ======================

 * Copyright (c) Charles Karney (2008-2022) <charles@karney.com> and licensed
 * under the MIT/X11 License.  For more information, see
 * https://geographiclib.sourceforge.io/
 **********************************************************************/

part of 'package:gc_wizard/tools/coords/_common/logic/external_libs/karney.geographic_lib/geographic_lib.dart';

const int _GEOGRAPHICLIB_TRANSVERSEMERCATOR_ORDER = 8;

// ignore_for_file: unused_field
// ignore_for_file: unused_element
class _TransverseMercator {
  final int maxpow_ = _GEOGRAPHICLIB_TRANSVERSEMERCATOR_ORDER;
  final int numit_ = 5;
  late double _a,


/*
Copyright (c) 2018-2023 Festo SE & Co. KG <https://www.festo.com/net/de_de/Forms/web/contact_international>
Author: Michael Hoffmeister

This source code is licensed under the Apache License 2.0 (see LICENSE.txt).

This source code may use other Open Source software components (see LICENSE.txt).
*/

using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Shapes;
using System.Xml;

namespace WpfMtpControl
{
    // ReSharper disable once ClassNeverInstantiated.Global
    public class UIElementHelper
    {
        public static UIElement cloneElement(UIElement orig)
        {
            if (orig == null)
                return (null);

            string s = XamlWriter.Save(orig);
            StringReader stringReader = new StringReader(s);
            XmlReader xmlReader = XmlTextReader.Create(stringReader, new XmlReaderSettings());
            return (UIElement)XamlReader.Load(xmlReader);

        }

        public static Label FindLabelWithText(System.Windows.DependencyObject parent, string textToFind)
        {
            // trivial
            if (parent == null)
                return null;

            // recurse visual tree
            int childrenCount = System.Windows.Media.VisualTreeHelper.GetChildrenCount(parent);
            for (int i = 0; i < childrenCount; i++)
            {
                var child = System.Windows.Media.VisualTreeHelper.GetChild(parent, i);

                // deep inspect?
                var childLabel = child as Label;
                if (childLabel != null && childLabel.Content != null)
                {
                    var childLabelText = childLabel.Content as string;
                    if (childLabelText != null && childLabelText.Trim() == textToFind.Trim())
                        return childLabel;
                }

                // recurse?
                var childFound = FindLabelWithText(child, textToFind);
                if (childFound != null)
                    return childFound;
            }

            // no
            return null;
        }

        public static void ApplyMultiLabel(FrameworkElement contentObject, Tuple<string, string>[] labelTexts = null)
        {
            // trivial
            if (contentObject == null)
                return;

            // can name labels?
            if (labelTexts != null)
                foreach (var lt in labelTexts)
                {
                    var tagLebel = UIElementHelper.FindLabelWithText(contentObject, lt.Item1);
                    if (tagLebel != null)
                        tagLebel.Content = "" + lt.Item2;
                }
        }

        private static void FindNozzlesViaTagsIntern(
            System.Windows.DependencyObject parent, Dictionary<int, Point> namedNozzles,
            string matchHead, bool extractShapes = false)
        {
            // trivial
            if (parent == null || namedNozzles == null)
                return;

            var toExtract = new List<UIElement>();

            // recurse visual tree
            int childrenCount = System.Windows.Media.VisualTreeHelper.GetChildrenCount(parent);
            for (int i = 0; i < childrenCount; i++)
            {
                var child = System.Windows.Media.VisualTreeHelper.GetChild(parent, i);

                // deep inspect?
                var childEllipse = child as Ellipse;
                if (childEllipse != null)
                {
                    var childEllipseTagText = childEllipse.Tag as string;
                    if (childEllipseTagText != null && childEllipseTagText.Trim() != "")
                    {
                        var m = Regex.Match(childEllipseTagText, matchHead + @


              #75.5
        vmovupd   %zmm2, 64(%r13,%rax,8)                        #75.5
        addq      $16, %rax                                     #75.5
        cmpq      %r14, %rax                                    #75.5
        jb        ..B1.38       # Prob 82%                      #75.5
        movl      $222, %ebx # INSERTED BY KERNCRAFT IACA MARKER UTILITY
        .byte     100        # INSERTED BY KERNCRAFT IACA MARKER UTILITY
        .byte     103        # INSERTED BY KERNCRAFT IACA MARKER UTILITY
        .byte     144        # INSERTED BY KERNCRAFT IACA MARKER UTILITY


 log) and then we will stop when we receive the fake one
          soon.
        */
        if (raw_mode)
        {
          if (output_file != 0)
          {
            my_snprintf(log_file_name, sizeof(log_file_name), "%s%s",
                        output_file, rev->new_log_ident);
          }
          else
          {
            strmov(log_file_name, rev->new_log_ident);
          }
          log_file = log_file_name + dirname_length(log_file_name);
        }

        if (rev->when.tv_sec == 0)
        {
          if (!to_last_remote_log)
          {
            if ((rev->ident_len != logname_len) ||
                memcmp(rev->new_log_ident, logname, logname_len))
            {
              DBUG_RETURN(OK_CONTINUE);
            }
            /*
              Otherwise, this is a fake Rotate for our log, at the very
              beginning for sure. Skip it, because it was not in the original
              log. If we are running with to_last_remote_log, we print it,
              because it serves as a useful marker between binlogs then.
            */
            continue;
          }
          /*
             Reset the value of '# at pos' field shown against first event of
             next binlog file (fake rotate) picked by mysqlbinlog --to-last-log
         */
          old_off= start_position_mot;
          event_len = 0; // fake Rotate, so don't increment old_off
        }
      }
      else if (type == FORMAT_DESCRIPTION_EVENT)
      {
        /*
          This could be an fake Format_description_log_event that server
          (5.0+) automatically sends to a slave on connect, before sending
          a first event at the requested position.  If this is the case,
          don't increment old_off. Real Format_description_log_event always
          starts from BIN_LOG_HEADER_SIZE position.
        */
        // fake event when not in raw mode, don't increment old_off
        if ((old_off != BIN_LOG_HEADER_SIZE) && (!raw_mode))
          event_len = 0;
        if (raw_mode)
        {
          if (result_file && (result_file != stdout))
            my_fclose(result_file, MYF(0));
          if (!(result_file = my_fopen(log_file_name, O_WRONLY | O_BINARY,
                                       MYF(MY_WME))))
          {
            error("Could not create log file '%s'", log_file_name);
            DBUG_RETURN(ERROR_STOP);
          }
          DBUG_EXECUTE_IF("simulate_result_file_write_error_for_FD_event",
                          DBUG_SET("+d,simulate_fwrite_error"););
          if (my_fwrite(result_file, (const uchar*) BINLOG_MAGIC,
                        BIN_LOG_HEADER_SIZE, MYF(MY_NABP)))
          {
            error("Could not write into log file '%s'", log_file_name);
            DBUG_RETURN(ERROR_STOP);
          }
          /*
            Need to handle these events correctly in raw mode too
            or this could get messy
          */
          delete glob_description_event;
          glob_description_event= (Format_description_log_event*) ev;
          print_event_info->common_header_len= glob_description_event->common_header_len;
          ev->temp_buf= 0;
          ev= 0;
        }
      }

      if (type == LOAD_EVENT)
      {
        DBUG_ASSERT(raw_mode);
        warning("Attempting to load a remote pre-4.0 binary log that contains "


o_raw(e) as _)
                }
            }
        }

        Impl::new_ptr(move |$($arg : $arg_type),*| -> $ret_type { $($body)* })
    }}
}

// Call `AddRef` and convert to `ComRc`.
unsafe fn add_ref_to_rc<T: ComInterface + ?Sized>(
    ptr: *mut *mut <T as ComInterface>::VTable,
) -> ComRc<T> {
    let ptr = ComPtr::new(ptr);
    ptr.add_ref();
    ptr.upgrade()
}

/// `ICoreWebView2Environment`.
#[derive(Clone)]
pub struct Environment {
    inner: ComRc<dyn ICoreWebView2Environment>,
}

/// `ICoreWebView2Host`.
#[derive(Clone)]
pub struct Host {
    inner: ComRc<dyn ICoreWebView2Host>,
}

/// `ICoreWebView2`.
#[derive(Clone)]
#[repr(C)]
pub struct WebView {
    inner: ComRc<dyn ICoreWebView2>,
}

/// `ICoreWebView2Settings`.
#[derive(Clone)]
pub struct Settings {
    inner: ComRc<dyn ICoreWebView2Settings>,
}

/// `ICoreWebView2ContentLoadingEventArgs`.
#[derive(Clone)]
pub struct ContentLoadingEventArgs {
    inner: ComRc<dyn ICoreWebView2ContentLoadingEventArgs>,
}

/// `ICoreWebView2WebMessageReceivedEventArgs`.
#[derive(Clone)]
pub struct WebMessageReceivedEventArgs {
    inner: ComRc<dyn ICoreWebView2WebMessageReceivedEventArgs>,
}

/// `ICoreWebView2HttpHeadersCollectionIterator`.
#[derive(Clone)]
pub struct HttpHeadersCollectionIterator {
    inner: ComRc<dyn ICoreWebView2HttpHeadersCollectionIterator>,
}

/// `ICoreWebView2HttpRequestHeaders`.
#[derive(Clone)]
pub struct HttpRequestHeaders {
    inner: ComRc<dyn ICoreWebView2HttpRequestHeaders>,
}

/// `ICoreWebView2HttpResponseHeaders`.
#[derive(Clone)]
pub struct HttpResponseHeaders {
    inner: ComRc<dyn ICoreWebView2HttpResponseHeaders>,
}

/// `ICoreWebView2Deferral`.
#[derive(Clone)]
pub struct Deferral {
    inner: ComRc<dyn ICoreWebView2Deferral>,
}

/// `ICoreWebView2WebResourceRequest`.
#[derive(Clone)]
pub struct WebResourceRequest {
    inner: ComRc<dyn ICoreWebView2WebResourceRequest>,
}

/// `ICoreWebView2WebResourceResponse`.
#[derive(Clone)]
pub struct WebResourceResponse {
    inner: ComRc<dyn ICoreWebView2WebResourceResponse>,
}

/// `ICoreWebView2WebResourceRequestedEventArgs`.
#[derive(Clone)]
pub struct WebResourceRequestedEventArgs {
    inner: ComRc<dyn ICoreWebView2WebResourceRequestedEventArgs>,
}

/// `ICoreWebView2NavigationCompletedEventArgs`.
#[derive(Clone)]
pub struct NavigationCompletedEventArgs {
    inner: ComRc<dyn ICoreWebView2NavigationCompletedEventArgs>,
}

/// `ICoreWebView2NavigationStartingEventArgs`.
#[derive(Clone)]
pub struct NavigationStartingEventArgs {
    inner: ComRc<dyn ICoreWebView2NavigationStartingEventArgs>,
}

/// `ICoreWebView2SourceChangedEventArgs`.
#[derive(Clone)]
pub struct SourceChangedEventArgs {
    inner: ComRc<dyn ICoreWebView2SourceChangedEventArgs>,
}

/// `ICoreWebView2ScriptDialogOpeningEventArgs`.
#[derive(Clone)]
pub struct ScriptDialogOpeningEventArgs {
    inner: ComRc<dyn ICoreWebView2ScriptDialogOpeningEventArgs>,
}

/// `ICoreWebView2PermissionRequestedEventArgs`.
#[derive(Clone)]
pub struct PermissionRequestedEventArgs {
    inner: ComR


't open, ext
	end

	menuOpenTime = now

    SendNUIMessage({cmd = "openMenu", menuId = strMenuId, open = bOpen})

	if bOpen then
		currentMenu = strMenuId

		promptMenuSelect = PromptRegisterBegin()
        PromptSetControlAction(promptMenuSelect, `INPUT_GAME_MENU_ACCEPT`)
        PromptSetText(promptMenuSelect, CreateVarString(10, "LITERAL_STRING", "Select"))
        PromptRegisterEnd(promptMenuSelect)

		promptMenuBack = PromptRegisterBegin()
        PromptSetControlAction(promptMenuBack, `INPUT_GAME_MENU_CANCEL`)
        PromptSetText(promptMenuBack, CreateVarString(10, "LITERAL_STRING", "Back"))
        PromptRegisterEnd(promptMenuBack)

		W.UI.SetMenusVisibleAndActive(true)

		Citizen.CreateThread(function()
			while currentMenu == strMenuId do
				SetGameplayCamGranularFocusThisFrame(1.0, 1, 0.0, 1, 0.9)
				DisableCinematicModeThisFrame()
				Citizen.Wait(0)
			end
			SetGameplayCamGranularFocusThisFrame(0.0, 1, 0.0, 1, 0.0)
		end)
	else
		TriggerEvent('wild:cl_onMenuClosing', currentMenu)

		currentMenu = ""

		SetNuiFocus(false)
		W.UI.SetMenusVisibleAndActive(false)
		--[[Citizen.Wait(400)

		SetControlContext(0, prevCtrlCtx)]]

		PromptDelete(promptMenuSelect)
		PromptDelete(promptMenuBack)
		promptMenuSelect = 0
		promptMenuBack = 0
	end

	if bOpen then
		PlaySound("HUD_PLAYER_MENU", "MENU_ENTER")
	else
		PlaySound("HUD_PLAYER_MENU", "MENU_CLOSE")
	end
end

function W.UI.GetActivePrompt()
	return promptMenuSelect
end

function W.UI.IsAnyMenuOpen()
end

function W.UI.SetElementTextByClass(strMenuId, strClass, strText)
	SendNUIMessage({cmd = "setElementTextByClass", menuId = strMenuId, class = strClass, text = strText})
end

function W.UI.SetElementTextById(strMenuId, strId, strText)
	SendNUIMessage({cmd = "setElementTextById", menuId = strMenuId, id = strId, text = strText})
end

function W.UI.CreatePage(strMenuId, strPageId, strPageTitle, strPageSubtitle, iType, iDetailPanelSize)
	SendNUIMessage({cmd = "createPage", menuId = strMenuId, pageId = strPageId, pageTitle = strPageTitle, pageSubtitle = strPageSubtitle, type = iType, detailPanelSize = iDetailPanelSize})
end

function W.UI.EditPage(strMenuId, strPageId, strPageTitle, strPageSubtitle)
	SendNUIMessage({cmd = "editPage", menuId = strMenuId, pageId = strPageId, pageTitle = strPageTitle, pageSubtitle = strPageSubtitle})
end

function W.UI.CreatePageFilterIcons(strMenuId, strPageId, arrIcons)
	local res = GetInvokingResource()

	for i=1, #arrIcons do
		arrIcons[i] = "https://cfx-nui-"..res.."/" .. arrIcons[i]
	end

	SendNUIMessage({cmd = "createPageFilterIcons", menuId = strMenuId, pageId = strPageId, icons = arrIcons})
end

function W.UI.SelectPageFilterIcon(strMenuId, strPageId, iIndex)
	SendNUIMessage({cmd = "selectPageFilterIcon", menuId = strMenuId, pageId = strPageId, index = iIndex})
end

function W.UI.FeedbackFilter(bForward)
	SendNUIMess


orPath)).on('error', reject);
            }

            if (tarballCachePath) {
              integrityValidateStream.pipe(fs.createWriteStream(tarballCachePath)).on('error', reject);
            }

            integrityValidateStream.pipe(extractorStream).on('error', reject);
          }
        }, _this3.packageName);
      } catch (err) {
        const tarballMirrorPath = _this3.getTarballMirrorPath();
        const tarballCachePath = _this3.getTarballCachePath();

        if (tarballMirrorPath && (yield (_fs || _load_fs()).exists(tarballMirrorPath))) {
          yield (_fs || _load_fs()).unlink(tarballMirrorPath);
        }

        if (tarballCachePath && (yield (_fs || _load_fs()).exists(tarballCachePath))) {
          yield (_fs || _load_fs()).unlink(tarballCachePath);
        }

        throw err;
      }
    })();
  }

  requestHeaders() {
    const registry = this.config.registries.yarn;
    const config = registry.config;
    const requestParts = urlParts(this.reference);
    return Object.keys(config).reduce((headers, option) => {
      const parts = option.split(':');
      if (parts.length === 3 && parts[1] === '_header') {
        const registryParts = urlParts(parts[0]);
        if (requestParts.host === registryParts.host && requestParts.path.startsWith(registryParts.path)) {
          const headerName = parts[2];
          const headerValue = config[option];
          headers[headerName] = headerValue;
        }
      }
      return headers;
    }, {});
  }

  _fetch() {
    const isFilePath = this.reference.startsWith('file:');
    this.reference = (0, (_misc || _load_misc()).removePrefix)(this.reference, 'file:');
    const urlParse = url.parse(this.reference);

    // legacy support for local paths in yarn.lock entries
    const isRelativePath = urlParse.protocol ? urlParse.protocol.match(/^[a-z]:$/i) : urlParse.pathname ? urlParse.pathname.match(/^(?:\.{1,2})?[\\\/]/) : false;

    if (isFilePath || isRelativePath) {
      return this.fetchFromLocal(this.reference);
    }

    return this.fetchFromLocal().catch(err => this.fetchFromExternal());
  }

  _findIntegrity({ hashOnly }) {
    if (this.remote.integrity && !hashOnly) {
      return ssri.parse(this.remote.integrity);
    }
    if (this.hash) {
      return ssri.fromHex(this.hash, 'sha1');
    }
    return null;
  }

  _supportedIntegrity({ hashOnly }) {
    const expectedIntegrity = this._findIntegrity({ hashOnly }) || {};
    const expectedIntegrityAlgorithms = Object.keys(expectedIntegrity);
    const shouldValidateIntegrity = (this.hash || this.remote.integrity) && !this.config.updateChecksums;

    if (expectedIntegrityAlgorithms.length === 0 && (!shouldValidateIntegrity || hashOnly)) {
      const algorithms = this.config.updateChecksums ? ['sha512'] : ['sha1'];
      // for consistency, return sha1 for packages without a remote integrity (eg. github)
      return { integrity: null, algorithms };
    }

    const algorithms = new Set(['sha512', 'sha1']);
    const integrity = {};
    for (var _iterator = expectedIntegrityAlgorithms, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) {
      var _ref;

      if (_isArray) {
        if (_i >= _iterator.length) break;
        _ref = _iterator[_i++];
      } else {
        _i = _iterator.next();
        if (_i.done) break;
        _ref = _i.value;
      }

      const algorithm = _ref;

      if (isHashAlgorithmSupported(algorithm)) {
        algorithms.add(algorithm);
        integrity


glabel func_8011AF50
/* 0A39C0 8011AF50 27BDFFE0 */  addiu $sp, $sp, -0x20
/* 0A39C4 8011AF54 AFBF0014 */  sw    $ra, 0x14($sp)
/* 0A39C8 8011AF58 8C8E004C */  lw    $t6, 0x4c($a0)
/* 0A39CC 8011AF5C 0C047891 */  jal   func_8011E244
/* 0A39D0 8011AF60 AFAE001C */   sw    $t6, 0x1c($sp)
/* 0A39D4 8011AF64 8FAF001C */  lw    $t7, 0x1c($sp)
/* 0A39D8 8011AF68 91F80000 */  lbu   $t8, ($t7)
/* 0A39DC 8011AF6C 5458000D */  bnel  $v0, $t8, .L8011AFA4_ovl2
/* 0A39E0 8011AF70 8FBF0014 */   lw    $ra, 0x14($sp)
/* 0A39E4 8011AF74 0C047939 */  jal   func_8011E4E4
/* 0A39E8 8011AF78 24040053 */   li    $a0, 83
/* 0A39EC 8011AF7C 3C088005 */  lui   $t0, %hi(D_8004A7C4) # $t0, 0x8005
/* 0A39F0 8011AF80 8D08A7C4 */  lw    $t0,


(std::nullptr_t = nullptr) noexcept {}
        IHidGameControllerInputSink(void* ptr, take_ownership_from_abi_t) noexcept : winrt::Windows::Foundation::IInspectable(ptr, take_ownership_from_abi) {}
    };
    struct WINRT_IMPL_EMPTY_BASES IHidGameControllerProvider :
        winrt::Windows::Foundation::IInspectable,
        impl::consume_t<IHidGameControllerProvider>,
        impl::require<winrt::Windows::Gaming::Input::Custom::IHidGameControllerProvider, winrt::Windows::Gaming::Input::Custom::IGameControllerProvider>
    {
        IHidGameControllerProvider(std::nullptr_t = nullptr) noexcept {}
        IHidGameControllerProvider(void* ptr, take_ownership_from_abi_t) noexcept : winrt::Windows::Foundation::IInspectable(ptr, take_ownership_from_abi) {}
    };
    struct WINRT_IMPL_EMPTY_BASES IXusbGameControllerInputSink :
        winrt::Windows::Foundation::IInspectable,
        impl::consume_t<IXusbGameControllerInputSink>,
        impl::require<winrt::Windows::Gaming::Input::Custom::IXusbGameControllerInputSink, winrt::Windows::Gaming::Input::Custom::IGameControllerInputSink>
    {
        IXusbGameControllerInputSink(std::nullptr_t = nullptr) noexcept {}
        IXusbGameControllerInputSink(void* ptr, take_ownership_from_abi_t) noexcept : winrt::Windows::Foundation::IInspectable(ptr, take_ownership_from_abi) {}
    };
    struct WINRT_IMPL_EMPTY_BASES IXusbGameControllerProvider :
        winrt::Windows::Foundation::IInspectable,
        impl::consume_t<IXusbGameControllerProvider>,
        impl::require<winrt::Windows::Gaming::Input::Custom::IXusbGameControllerProvider, winrt::Windows::Gaming::Input::Custom::IGameControllerProvider>
    {
        IXusbGameControllerProvider(std::nullptr_t = nullptr) noexcept {}
        IXusbGameControllerProvider(void* ptr, take_ownership_from_abi_t) noexcept : winrt::Windows::Foundation::IInspectable(ptr, take_ownership_from_abi) {}
    };
}
#endif


# control_any_auto.py  29/05/2016  D.J.Whale
#
# Demonstrates the variable auto-create.
#
# Variables are auto created into a given context, entirely from the registry.
# You should seed the registry first with setup_tool.py and give the devices
# the correct names, before this will work.

import time

try:
    # Python 3
    from . import energenie
except ImportError:
    # Python 2
    import energenie

APP_DELAY = 1

def auto_loop():

    # Use the auto-generated variables 'fan' and 'tv'.
    # These can be any device that has a switch.
    # They must be defined with these names in the registry for this code to work.
    print("Turning ON")
    fan.turn_on()
    tv.turn_on()
    time.sleep(APP_DELAY)

    print("Turning OFF")
    fan.turn_off()
    tv.turn_off()
    time.sleep(APP_DELAY)

if __name__ == "__main__":

    print("Starting auto example")

    energenie.init()

    # Load all devices into variables auto created in the global scope
    # You can pass any context here, such as a class to contain your devices
    import sys
    me_global = sys.modules[__name__]
    energenie.registry.load_into(me_global)

    try:
        while True:
            auto_loop()

    finally:
        energenie.finished()

# END


Property(window, "a", {
  get () {
    return this.arr.shift()
  }
})
if (a === 1 && a === 2 && a === 3) {
  console.log('成立')
}
```

中了`shift()`的毒...当然，这样也是可以实现的。

**解法三**

还有就是[EnoYao](https://juejin.im/user/584c7f44ac502e0069275cd7)大佬那里看来的骚操作：

原文链接：https://juejin.im/post/5e66dc416fb9a07cab3aaa0a

```javascript
var a = 1;
var a = 2;
var a = 3;
if (a == 1 && a == 2 && a == 3) {
  console.log("成立");
}
```

说来惭愧...`a`的前后隐藏的字符我打不来 😂...

### 9. 控制台输入{}+[]会怎样？

这道有趣的题是从[LINGLONG](https://juejin.im/user/5cd2341ce51d456e5c5baba3)的一篇[《【js小知识】[]+ {} =？/{} +[] =?（关于加号的隐式类型转换）》](https://juejin.im/post/5e605528518825495c659769)那里看来的。

(PS: pick一波玲珑，这位小姐姐的文章写的都挺好的，不过热度都不高，大家可以支持一下呀 😁)

OK👌，来看看题目是这样的：

在控制台(比如浏览器的控制台)输入:

```javascript
{}+[]
```

的结果会是什么 🤔？

咦～这道题应该很简单吧，根据前面的类型转换原则，`+`两边都转换为字符串，`{}`转为`"[object Object]"`，`[]`转为`""`，拼接的结果就是：

```javascript
console.log({}+[]) // "[object Object]"
```

但是注意这里的题目，是要在控制台输出哦。

此时我把这段代码在控制台输出结果发现答案竟然和预期的不一样：

```javascript
{}+[]
0
```

也就是说`{}`被忽略了，直接执行了`+[]`，结果为`0`。

知道原因的我眼泪掉了下来，原来它和之前提到的`1.toString()`有点像，也是因为`JS`对于代码解析的原因，在控制台或者终端中，`JS`会认为大括号`{}`开头的是一个空的代码块，这样看着里面没有内容就会忽略它了。

所以只执行了`+[]`，将其转换为`0`。

如果我们换个顺序的话就不会有这种问题：

![](https://user-gold-cdn.xitu.io/2020/4/3/1713ef9519c4a708?w=594&h=460&f=jpeg&s=41829)

(图片来源：https://juejin.im/post/5e605528518825495c659769#


Queue{
		first: chunk,
		last:  chunk,
	}
}

func (q *eventQueue) pushBack(e sharedMuxEvent) {
	if q.write == eventQueueChunkSize {
		nextChunk := getPooledQueueChunk()
		q.last.nextChunk = nextChunk
		q.last = nextChunk
		q.write = 0
	}
	q.last.data[q.write] = e
	q.write++
	q.size++
}

func (q *eventQueue) popFront() (sharedMuxEvent, bool) {
	if q.size == 0 {
		return sharedMuxEvent{}, false
	}
	if q.read == eventQueueChunkSize {
		removed := q.first
		q.first = q.first.nextChunk
		putPooledQueueChunk(removed)
		q.read = 0
	}
	res := q.first.data[q.read]
	q.first.data[q.read] = sharedMuxEvent{}
	q.read++
	q.size--
	return res, true
}

// free drops references held by the queue.
func (q *eventQueue) free() {
	q.first = nil
	q.last = nil
	q.read = 0
	q.write = 0
	q.size = 0
}

// drain releases all allocations held by the queue and then frees it.
func (q *eventQueue) drain(ctx context.Context) {
	start := q.read
	for chunk := q.first; chunk != nil; {
		max := eventQueueChunkSize
		if chunk.nextChunk == nil {
			max = q.write
		}
		for i := start; i < max; i++ {
			item := chunk.data[i]
			chunk.data[i] = sharedMuxEvent{}
			item.alloc.Release(ctx)
		}
		next := chunk.nextChunk
		putPooledQueueChunk(chunk)
		chunk = next
		start = 0
	}
	q.free()
}

func (q *eventQueue) len() int64 {
	return int64(q.size)
}

func (q *eventQueue) empty() bool {
	return q.size == 0
}
// Copyright 2024 The Cockroach Authors.
//
// Use of this software is governed by the CockroachDB Software License
// included in the /LICENSE file.

package rangefeed

import (
	"math/rand"

	"github.com/cockroachdb/cockroach/pkg/keys"
	"github.com/cockroachdb/cockroach/pkg/roachpb"
	"github.com/cockroachdb/cockroach/pkg/sql/rowenc/keyside"
	"github.com/cockroachdb/cockroach/pkg/sql/sem/tree"
	"github.com/cockroachdb/cockroach/pkg/util/encoding"
	"github.com/cockroachdb/cockroach/pkg/util/hlc"
)

// GenerateRandomizedTs generates a timestamp between 1 and ns nanoseconds.
func GenerateRandomizedTs(rand *rand.Rand, maxTime int64) hlc.Timestamp {
	// Avoid generating zero timestamp which will equal to an empty event.
	return hlc.Timestamp{WallTime: rand.Int63n(maxTime) + 1}
}

func generateStartAndEndKey(rand *rand.Rand) (roachpb.Key, roachpb.Key) {
	startKey, endKey, _ := generateStartAndEndKeyFromK(rand, 0)
	return startKey, endKey
}

// generateStartAndEndKey generates a start key at or above k, an end key at or
// above the start key, and returns the keys and the value of the end key.
func generateStartAndEndKeyFromK(rand *rand.Rand, k int) (roachpb.Key, roachpb.Key, int) {
	start := k + rand.Intn(2<<20)
	end := start + rand.Intn(2<<20)
	startDatum := tree.NewDInt(tree.DInt(start))
	endDatum := tree.NewDInt(tree.DInt(end))
	const tableID = 42

	startKey, err := keyside.Encode(
		keys.SystemSQLCodec.TablePrefix(tableID),
		startDatum,
		encoding.Ascending,
	)
	if err != nil {
		panic(err)
	}

	endKe


   田贵祥，男，现年三十五岁，汉族，家庭成份小土地经营，个人成分学生，高中文化程度，沿河县城关公社黑水管理区人，五四年八月入党，现任县委驻团结村工作组长兼燎原管理区总支书记。

   一、 简历：

   三四年至四四年读书，四五年至四八年在铜仁读师范，在校参加三青团，后任“新东晚报采访”，印文乡副乡长，四八年毕业回沿河任黑水、永祥伪小学校长、教导主任，四九年任伪黑水乡公所户籍干事、民政干事，解放前夕参加肖进坤匪部任副官，田粮稽征员，五○年当地解放后暗任匪副官职务，保留委任状参加我政府工作，历任副科长、秘书、支书等职。

   二、 社会关系：

   肖进坤，伪乡长，土匪大队长（已决），叔侄关系，系田的伪职上司。

   刘筱齐，大恶霸，内亲，解放前供田读中学，教其发展至上，升官发财（刘已决）。

   三、错误事实：

   （1）残害群众，五九年腊月崔兰英的猪被盗，小队长李素英强制群众进行搜查，搜查时在田世江（贫农）家中查出猪头一个，肉一腿，不问清由，将田吊在食堂的川川上打了两棒，早饭后，小队长李素英将田绑送管理区，交田贵祥进行处理，田将田世江打了一顿以后，召开群众会进行斗争，斗争中，田贵祥已发现田世江因受伤过重，情况非常危险，但不加以纠正，斗争后责成青年队强制劳动，青年队眼见田世江做不得什么，便将田放回家去，田回去的第三天，田贵祥亲自组织群众在天官庙开会斗争，罚站斗争三个钟头，当时田世江已坐立不住，放回家去就死在半路上。

   （2）五九年十二月二十号晚上，田贵祥从鸟窝平回管理区，走至墨井弯，发现有人打菜，田不问清楚，开枪打人（未打中）。

   （3）同月贫农肖世全偷杀羊子一只，田将其捆送管理区，叫田永章打肖打了一顿，关两天一夜，召开群众会脱衣斗争。

   （4）利用职权，打击陷害群众，六○年二月有九户农民不执行田的错误主张，而被他强制搬家，今年二月整风整社期间，管理区田茂远等两人提出他的意见，田仅滥用职权将两人宣布开除党籍回家生产。开除三个党员的党籍，撤�


;faces dessous

	INV4	2,-1,9,17,16,8
	INV4	3,-1,10,18,17,9
	INV4	2,-1,11,19,18,10
	INV4	3,-1,12,20,19,11
	INV4	2,-1,13,21,20,12
	INV4	3,-1,14,22,21,13
	INV4	2,-1,15,23,22,14
	INV4	3,-1,8,16,23,15
	rts

pchiffre8
	dc.w	14

	DC.W	-20,30,0
	DC.W	20,30,0
	DC.W	-10,20,0
	DC.W	10,20,0
	DC.W	-10,5,0
	DC.W	10,5,0
	DC.W	-20,0,0
	DC.W	20,0,0
	DC.W	-10,-5,0
	DC.W	10,-5,0
	DC.W	-10,-20,0
	DC.W	10,-20,0
	DC.W	-20,-30,0
	DC.W	20,-30,0

fchiffre8
	INV4	0,-1,1,0,2,3
	INV4	0,-1,0,6,4,2
	INV4	0,-1,1,3,5,7
	INV6	0,-1,5,4,6,8,9,7
	INV4	0,-1,6,12,10,8
	INV4	0,-1,9,11,13,7
	INV4	0,-1,10,12,13,11
	rts

plettrea
	dc.w	11

	DC.W	-5,20,5
	DC.W	5,20,5
	DC.W	0,10,5
	DC.W	-8,-5,5
	DC.W	8,-5,5
	DC.W	-10,-10,5
	DC.W	10,-10,5
	DC.W	-25,-20,5
	DC.W	-15,-20,5
	DC.W	15,-20,5
	DC.W	25,-20,5

flettrea
	INV4	0,-1,0,7,8,1
	INV4	0,-1,9,10,1,0
	INV4	0,-1,3,5,6,4

	INV4	1,-1,0,1,8,7
	INV4	1,-1,9,0,1,10
	INV4	1,-1,3,4,6,5
	rts

pdalle
	dc.w	4
	DC.W	50,50,0
	DC.W	50,-50,0
	DC.W	-50,-50,0
	DC.W	-50,50,0

fdalle
	INV4	0,-1,3,2,1,0
	INV4	1,-1,0,1,2,3
	rts

puncube
	dc.w	8

	DC.W	-35,35,15
	DC.W	-5,35,15
	DC.W	-5,5,15
	DC.W	-35,5,15
	DC.W	-35,35,-15
	DC.W	-5,35,-15
	DC.W	-5,5,-15
	DC.W	-35,5,-15

funcube
	INV4	0,-1,1,2,6,5
	INV4	1,-1,3,2,1,0
	INV4	0,-1,1,5,4,0
	INV4	2,-1,0,4,7,3
	INV4	3,-1,3,7,6,2
	INV4	1,


"    end","  end","  return 0","end"]))+"("+c+", "+b+")",Blockly.Lua.ORDER_HIGH]};Blockly.Lua.lists.getIndex_=function(a,b,c){return"FIRST"==b?"1":"FROM_END"==b?"#"+a+" + 1 - "+c:"LAST"==b?"#"+a:"RANDOM"==b?"math.random(#"+a+")":c};
Blockly.Lua.lists_getIndex=function(a){var b=a.getFieldValue("MODE")||"GET",c=a.getFieldValue("WHERE")||"FROM_START",d=Blockly.Lua.valueToCode(a,"VALUE",Blockly.Lua.ORDER_HIGH)||"{}",e=Blockly.Lua.lists.getIndex_;if("LAST"!=c&&"FROM_END"!=c&&"RANDOM"!=c||d.match(/^\w+$/)){f="GET"==b&&"FROM_END"==c?Blockly.Lua.ORDER_ADDITIVE:Blockly.Lua.ORDER_NONE;a=Blockly.Lua.valueToCode(a,"AT",f)||"1";a=e(d,c,a);if("GET"==b)return[d+"["+a+"]",Blockly.Lua.ORDER_HIGH];c="table.remove("+d+", "+a+")";return"GET_REMOVE"==
b?[c,Blockly.Lua.ORDER_HIGH]:c+"\n"}if("REMOVE"==b){var f="FROM_END"==c?Blockly.Lua.ORDER_ADDITIVE:Blockly.Lua.ORDER_NONE;a=Blockly.Lua.valueToCode(a,"AT",f)||"1";b=Blockly.Lua.variableDB_.getDistinctName("tmp_list",Blockly.Variables.NAME_TYPE);a=e(b,c,a);return b+" = "+d+"\ntable.remove("+b+", "+a+")\n"}a=Blockly.Lua.valueToCode(a,"AT",Blockly.Lua.ORDER_NONE)||"1";return[("GET"==b?Blockly.Lua.provideFunction_("list_get_"+c.toLowerCase(),["function "+Blockly.Lua.FUNCTION_NAME_PLACEHOLDER_+"(t"+("FROM_END"==
c||"FROM_START"==c?", at)":")"),"  return t["+e("t",c,"at")+"]","end"]):Blockly.Lua.provideFunction_("list_remove_"+c.toLowerCase(),["function "+Blockly.Lua.FUNCTION_NAME_PLACEHOLDER_+"(t"+("FROM_END"==c||"FROM_START"==c?", at)":")"),"  return table.remove(t, "+e("t",c,"at")+")","end"]))+"("+d+("FROM_END"==c||"FROM_START"==c?", "+a:"")+")",Blockly.Lua.ORDER_HIGH]};
Blockly.Lua.lists_setIndex=function(a){var b=Blockly.Lua.valueToCode(a,"LIST",Blockly.Lua.ORDER_HIGH)||"{}",c=a.getFieldValue("MODE")||"SET",d=a.getFieldValue("WHERE")||"FROM_START",e=Blockly.Lua.valueToCode(a,"AT",Blockly.Lua.ORDER_ADDITIVE)||"1";a=Blockly.Lua.valueToCode(a,"TO",Blockly.Lua.ORDER_NONE)||"None";var f=Blockly.Lua.lists.getIndex_,g="";if(("LAST"==d||"FROM_END"==d||"RANDOM"==d)&&!b.match(/^\w+$/)){var h=Blockly.Lua.variableDB_.getDistinctName("tmp_list",Blockly.Variables.NAME_TYPE);
g=h+" = "+b+"\n";b=h}g="SET"==c?g+(b+"["+f(b,d,e)+"] = "+a):g+("table.insert("+b+", "+(f(b,d,e)+("LAST"==d?" + 1":""))+", "+a+")");


0.9% 54.285714%, 51% 54.161491%, 51% 53.78882%, 50.9% 53.664596%, 50.9% 53.540373%, 50.8% 53.416149%);
    background-color: rgb(253, 254, 253)
    }
.component-377 {
    clip-path: polygon(46.7% 58.509317%, 46.6% 58.63354%, 46.9% 59.006211%, 47% 59.006211%, 47.1% 58.881988%, 46.8% 58.509317%);
    background-color: rgb(121, 8, 96)
    }
.component-378 {
    clip-path: polygon(47.5% 27.57764%, 47% 28.198758%, 47% 28.944099%, 47.1% 29.068323%, 47.1% 29.192547%, 47.4% 29.565217%, 47.5% 29.565217%, 47.6% 29.689441%, 47.9% 29.689441%, 48% 29.565217%, 48.1% 29.565217%, 48.4% 29.192547%, 48.4% 29.068323%, 48.5% 28.944099%, 48.5% 28.198758%, 48% 27.57764%);
    background-color: rgb(18, 19, 26)
    }
.component-379 {
    clip-path: polygon(47.5% 28.322981%, 47.6% 28.198758%, 47.8% 28.198758%, 47.9% 28.322981%, 47.9% 28.571429%, 47.8% 28.695652%, 47.6% 28.695652%, 47.5% 28.571429%);
    background-color: rgb(18, 19, 26)
    }
.component-380 {
    clip-path: polygon(47.9% 18.385093%, 47.7% 18.63354%, 47.2% 18.63354%, 47.1% 18.757764%, 47.2% 18.881988%, 47.6% 18.881988%, 47.7% 19.006211%, 48% 19.006211%, 48.1% 19.130435%, 48.3% 19.130435%, 48.4% 19.254658%, 48.7% 19.254658%, 48.8% 19.378882%, 48.9% 19.378882%, 49% 19.503106%, 49.1% 19.503106%, 49.2% 19.627329%, 49.3% 19.627329%, 49.4% 19.751553%, 49.5% 19.751553%, 49.6% 19.875776%, 49.8% 19.875776%, 50% 20.124224%, 50.1% 20.124224%, 50.2% 20.248447%, 50.3% 20.248447%, 50.8% 20.869565%, 50.9% 20.869565%, 51% 20.993789%, 51.1% 20.993789%, 51.2% 21.118012%, 51.2% 21.242236%, 51.3% 21.36646%, 51.3% 21.614907%, 51.2% 21.73913%, 51.3% 21.863354%, 51.3% 21.987578%, 51.2% 22.111801%, 51.4% 22.360248%, 52.4% 22.360248%, 52.6% 22.111801%, 52.6% 21.490683%, 52.5% 21.36646%, 52.5% 21.242236%, 52.1% 20.745342%, 52% 20.745342%, 51.7% 20.372671%, 51.6% 20.372671%, 51.4% 20.124224%, 51.3% 20.124224%, 51.2% 20%, 51.1% 20%, 51% 19.875776%, 50.9% 19.875776%, 50.8% 19.751553%, 50.7% 19.751553%, 50.6% 19.627329


xtra = append(resp.Extra, a)
	}

	// We don't know the exact trim, but we know the resulting answer
	// data should match its extra data.
	if trimmed := trimUDPResponse(req, resp, cfg.DNSUDPAnswerLimit); !trimmed {
		t.Fatalf("Bad %#v", *resp)
	}
	if len(resp.Answer) == 0 || len(resp.Answer) != len(resp.Extra) {
		t.Fatalf("Bad %#v", *resp)
	}
	for i := range resp.Answer {
		srv, ok := resp.Answer[i].(*dns.SRV)
		if !ok {
			t.Fatalf("should be SRV")
		}

		a, ok := resp.Extra[i].(*dns.A)
		if !ok {
			t.Fatalf("should be A")
		}

		if srv.Target != a.Header().Name {
			t.Fatalf("Bad %#v vs. %#v", *srv, *a)
		}
	}
}

func TestDNS_trimUDPResponse_TrimSizeEDNS(t *testing.T) {
	cfg := loadRuntimeConfig(t, `node_name = "test" data_dir = "a" bind_addr = "127.0.0.1" `)

	req, resp := &dns.Msg{}, &dns.Msg{}

	for i := 0; i < 100; i++ {
		target := fmt.Sprintf("ip-10-0-1-%d.node.dc1.consul.", 150+i)
		srv := &dns.SRV{
			Hdr: dns.RR_Header{
				Name:   "redis-cache-redis.service.consul.",
				Rrtype: dns.TypeSRV,
				Class:  dns.ClassINET,
			},
			Target: target,
		}
		a := &dns.A{
			Hdr: dns.RR_Header{
				Name:   target,
				Rrtype: dns.TypeA,
				Class:  dns.ClassINET,
			},
			A: net.ParseIP(fmt.Sprintf("10.0.1.%d", 150+i)),
		}

		resp.Answer = append(resp.Answer, srv)
		resp.Extra = append(resp.Extra, a)
	}

	// Copy over to a new slice since we are trimming both.
	reqEDNS, respEDNS := &dns.Msg{}, &dns.Msg{}
	reqEDNS.SetEdns0(2048, true)
	respEDNS.Answer = append(respEDNS.Answer, resp.Answer...)
	respEDNS.Extra = append(respEDNS.Extra, resp.Extra...)

	// Trim each response
	if trimmed := trimUDPResponse(req, resp, cfg.DNSUDPAnswerLimit); !trimmed {
		t.Errorf("expected response to be trimmed: %#v", resp)
	}
	if trimmed := trimUDPResponse(reqEDNS, respEDNS, cfg.DNSUDPAnswerLimit); !trimmed {
		t.Errorf("expected edns to be trimmed: %#v", resp)
	}

	// Check answer lengths
	if len(resp.Answer) == 0 || len(resp.Answer) != len(resp.Extra) {
		t.Errorf("bad response answer length: %#v", resp)
	}
	if len(respEDNS.Answer) == 0 || len(respEDNS.Answer) != len(respEDNS.Extra) {
		t.Errorf("bad edns answer length: %#v", resp)
	}

	// Due to the compression, we can't check exact equality of sizes, but we can
	// make two requests and ensure that the edns one returns a larger payload
	// than the non-edns0 one.
	if len(resp.Answer) >= len(respEDNS.Answer) {


li>

Let's take a look at the rules that exist for the input chain, as we've only created entries in our security groups for inbound traffic, noting that we're remotely executing these commands on the compute node that our instance is running on, adjust this to suit your environment:

$ ssh root@summit-compute2 iptables -S | grep 6b9ccfcf-9
-N neutron-openvswi-i6b9ccfcf-9
-N neutron-openvswi-o6b9ccfcf-9
-N neutron-openvswi-s6b9ccfcf-9
(snip)
-A neutron-openvswi-i6b9ccfcf-9 -p icmp -j RETURN                        <-- here's our icmp rule
-A neutron-openvswi-i6b9ccfcf-9 -p tcp -m tcp --dport 22 -j RETURN       <-- here's our ssh rule
-A neutron-openvswi-i6b9ccfcf-9 -p tcp -m tcp --dport 80 -j RETURN       <-- here's our http rule
(snip)

NOTE: I've slightly modified the output above to show the most important rules as dictated by the security group choices that we made before, primarily allowing port 22/tcp and 80/tcp, and ICMP (ping) from everywhere. Your output will show a lot more rules, primarily for things like allowing DHCP, preventing spoofing, and allowing existing connections. I've annotated the above too.

As you can see, it's relatively easy to view the iptables rules that are governed by Neutron's security group rules. These are dynamically updated upon security group modification so that any security changes are almost instantaneously reflected in the configuration.

Next, let's check out how the NAT-based routing is implemented by the L3 agent on the dedicated network node (summit-networker). It's possible to have multple L3 agents for high availability and load sharing, and it's also possible to have the L3 functionality being taken care of by the compute nodes themselves, which we call Distributed Virtual Routing (DVR), but we're using the legacy approach here with a single L3 agent for simplicity.

Earlier in this lab we configured a virtual router, this is what the L3 agent is responsible for creating and maintaining. The virtual routers are scheduled across any nodes within the cluster that are both running the L3 agent daemon, and have connectivity to the external network being requested. Within our environment we only have one L3 agent daemon running on a single system, so we know where the virtual router will be scheduled.

Each virtual router runs within its own network namespace on the host in which it has been schedule to run on, with the namespace being uniquely identified by the ID of the virtual router itself:

$ openstack router list
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+
| ID                                   | Name        | Status | State | Distributed | HA    | Project                          |
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+
| f8d34761-f57b-4697-8e37-741f274c4ff4 | demo_router | ACTIVE | UP    | False       | False | f991d44fac91419c8e6016184381871a |
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+

$ ssh root@summit-networker ip netns list | grep router
qrouter-808f8855-0e10-4749-ba2f-bff9ebacb102

NOTE: In the above output, note that the qrouter namespace matches to the router ID

Inside of this namespace is where iptables is used to perform both DN


0}_NH2(_vB2){_vB2._9i1=_vB2.target._Oy1()&&(!_vB2.data._ME2||this.skin&&_9z2._dz2(this.skin._142,
_vB2.data,!0));if(!_vB2._9i1)return;this._PH2(_vB2.target);let _QH2=_vB2.bones;let _IG2=_QH2.length;if(_vB2.data._W_){for(let _i4=0;_i4<_IG2;_i4++){let _iG2=_QH2[_i4];this._PH2(_iG2.parent);this._PH2(_iG2)}}else {for(let _i4=0;_i4<_IG2;_i4++){this._PH2(_QH2[_i4])}}this._AH2.push(_vB2);for(let _i4=0;_i4<_IG2;_i4++)this._RH2(_QH2[_i4]._EF1);for(let _i4=0;_i4<_IG2;_i4++)_QH2[_i4]._TE2=!0}_TH2(skin,_7B2,_SH2){let attachments=skin.attachments[_7B2];if(!attachments)return;for(let key in attachments){this._UH2(attachments[key],
_SH2)}}_UH2(attachment,_SH2){if(!(attachment instanceof _my2))return;let _VH2=attachment.bones;if(!_VH2)this._PH2(_SH2);else {let bones=this.bones;for(let _i4=0,_SQ=_VH2.length;_i4<_SQ;){let _WH2=_VH2[_i4++];_WH2+=_i4;while(_i4<_WH2)this._PH2(bones[_VH2[_i4++]])}}}_PH2(bone){if(bone._TE2)return;let parent=bone.parent;if(parent)this._PH2(parent);bone._TE2=!0;this._AH2.push(bone)}_RH2(bones){for(let _i4=0,_SQ=bones.length;_i4<_SQ;_i4++){let bone=bones[_i4];if(!bone._9i1)continue;if(bone._TE2)this._RH2(bone._EF1);
bone._TE2=!1}}_5Q(){let bones=this.bones;for(let _i4=0,_SQ=bones.length;_i4<_SQ;_i4++){let bone=bones[_i4];bone._Jo1=bone.x;bone._Ko1=bone.y;bone._OE2=bone.rotation;bone._PE2=bone.scaleX;bone._QE2=bone.scaleY;bone._RE2=bone.shearX;bone._SE2=bone.shearY}let _GH2=this._AH2;for(let _i4=0,_SQ=_GH2.length;_i4<_SQ;_i4++)_GH2[_i4]._gQ()}_VE2(parent){let _XH2=this._1Q();let _1_1=parent._9T,_2_1=parent._9R,_JY1=parent._j4,_ZE2=parent._ma1;_XH2._Zz2=_1_1*this.x+_2_1*this.y+parent._Zz2;_XH2.__z2=_JY1*this.x+_ZE2*this.y+parent.__z2;
let _WE2=_XH2.rotation+90+_XH2.shearY;let __E2=_jy2._sz2(_XH2.rotation+_XH2.shearX)*_XH2.scaleX;let _0F2=_jy2._sz2(_WE2)*_XH2.scaleY;let _1F2=_jy2._vz2(_XH2.rotation+_XH2.shearX)*_XH2.scaleX;let _2F2=_jy


            InvalidateRect(hwnd, 0, TRUE);
        }
        break;

    }

    return DefWindowProc(hwnd, wm, wp, lp);
}

/*****************************************************************************
 *
 *  WinMain
 *
 *      Program entry point.
 *
 *      Register the class, create the window, and go into a message loop.
 *
 *****************************************************************************/

int WINAPI
WinMain(HINSTANCE hinst, HINSTANCE hinstPrev, LPSTR pszCmdLine, int nCmdShow)
{
    HWND hwnd;
    MSG msg;
    WNDCLASS wc = {
        0,
        Hilbert_WndProc,
        0,
        0,
        hinst,
        LoadIcon(0, IDI_APPLICATION),
        LoadCursor(0, IDC_ARROW),
        (HBRUSH)(COLOR_WINDOW+1),
        0,
        TEXT("Hilbert")
    };

    RegisterClass(&wc);
    hwnd = CreateWindow(TEXT("Hilbert"),
		                TEXT("Hilbert"), WS_OVERLAPPEDWINDOW,
                        CW_USEDEFAULT, CW_USEDEFAULT,
                        CW_USEDEFAULT, CW_USEDEFAULT,
                        0, 0, hinst, 0);
    ShowWindow(hwnd, nCmdShow);
    while (GetMessage(&msg, 0, 0, 0)) {
        TranslateMessage(&msg);
        DispatchMessage(&msg);
    }

    return 0;
}


arithmetic::traits::Samplable;
use crate::BigInt;
use crate::ErrorKey::{self};

use std::ptr;
use std::sync::atomic;
use zeroize::Zeroize;

#[cfg(feature = "merkle")]
use crypto::digest::Digest;
#[cfg(feature = "merkle")]
use crypto::sha3::Sha3;
#[cfg(feature = "merkle")]
use merkle::Hashable;

#[derive(Clone, Copy)]
pub struct FieldScalar {
    purpose: &'static str,
    fe: SK,
}
#[derive(Clone, Copy)]
pub struct G1Point {
    purpose: &'static str,
    ge: PK,
}
pub type GE = G1Point;
pub type FE = FieldScalar;

impl Zeroize for FieldScalar {
    fn zeroize(&mut self) {
        unsafe { ptr::write_volatile(self, FE::zero()) };
        atomic::fence(atomic::Ordering::SeqCst);
        atomic::compiler_fence(atomic::Ordering::SeqCst);
    }
}

impl ECScalar<SK> for FieldScalar {
    fn new_random() -> FieldScalar {
        let rnd_bn = BigInt::sample_below(&FE::q());
        ECScalar::from(&rnd_bn)
    }

    fn zero() -> FieldScalar {
        FieldScalar {
            purpose: "zero",
            fe: SK::zero(),
        }
    }

    fn get_element(&self) -> SK {
        self.fe
    }
    fn set_element(&mut self, element: SK) {
        self.fe = element
    }

    fn from(n: &BigInt) -> FieldScalar {
        let n_mod = BigInt::modulus(n, &FE::q());
        let mut v = BigInt::to_vec(&n_mod);
        let mut bytes_array: [u8; SECRET_KEY_SIZE];
        if v.len() < SECRET_KEY_SIZE {
            let mut template = vec![0; SECRET_KEY_SIZE - v.len()];
            template.extend_from_slice(&v);
            v = template;
        }
        bytes_array = [0; SECRET_KEY_SIZE];
        let bytes = &v[..SECRET_KEY_SIZE];
        bytes_array.copy_from_slice(&bytes);

        bytes_array.reverse();

        FieldScalar {
            purpose: "from_big_int",
            fe: SK::from_bytes(&bytes_array).unwrap(),
        }
    }

    fn to_big_int(&self) -> BigInt {
        let mut bytes = SK::to_bytes(&self.fe);
        bytes.reverse();
        BigInt::from(&bytes[..])
    }

    fn q() -> BigInt {
        let q_u64: [u64; 4] = [
            0xffffffff00000001,
            0x53bda402fffe5bfe,
            0x3339d80809a1d805,
            0x73eda753299d7d48,
        ];
        let to_bn = q_u64.iter().rev().fold(BigInt::zero(), |acc, x| {
            let element_bn = BigInt::from(*x);
            element_bn + (acc << 64)
        });
        to_bn
    }

    fn add(&self, other: &SK) -> FieldScalar {
        let add_fe = FieldScalar {
            purpose: "other add",
            fe: *other,
        };
        let res = add_fe.fe.add(&self.fe);
        FieldScalar {
            purpose: "add",
            fe: res,
        }
    }

    fn mul(&self, other: &SK) -> FieldScalar {
        let mul_fe = FieldScalar {
            purpose: "other mul",
            fe: *other,
        };
        let res = mul_fe.fe.mul(&self.fe);
        FieldScalar {
            purpose: "mul",
            fe: res,
        }
    }

    fn sub(&self, oth


.villageQuestGivers .questGiver .questMarkerContent{position:absolute;-webkit-border-radius:50% 50% 0 50%;-moz-border-radius:50% 50% 0 50%;-ms-border-radius:50% 50% 0 50%;-o-border-radius:50% 50% 0 50%;border-radius:50% 50% 0 50%}.villageQuestGivers .questGiver .questMarker{top:-40px;right:-23px;width:30px;height:30px;border:1px solid #fff;-webkit-transform:rotate(45deg) translateZ(0);-moz-transform:rotate(45deg) translateZ(0);-ms-transform:rotate(45deg) translateZ(0);-o-transform:rotate(45deg) translateZ(0);transform:rotate(45deg) translateZ(0);background-image:-owg-linear-gradient(to bottom left,#fff,#fff 50%,#b2b2b2 90%,#b8b2a9);background-image:-webkit-linear-gradient(to bottom left,#fff,#fff 50%,#b2b2b2 90%,#b8b2a9);background-image:-moz-linear-gradient(to bottom left,#fff,#fff 50%,#b2b2b2 90%,#b8b2a9);background-image:-o-linear-gradient(to bottom left,#fff,#fff 50%,#b2b2b2 90%,#b8b2a9);background-image:linear-gradient(to bottom left,#fff,#fff 50%,#b2b2b2 90%,#b8b2a9);-webkit-box-shadow:2px 2px 10px 0 rgba(0,0,0,0.5);-moz-box-shadow:2px 2px 10px 0 rgba(0,0,0,0.5);box-shadow:2px 2px 10px 0 rgba(0,0,0,0.5)}.villageQuestGivers .questGiver .questMarkerContent{-webkit-transform:rotate(-45deg);-moz-transform:rotate(-45deg);-ms-transform:rotate(-45deg);-o-transform:rotate(-45deg);transform:rotate(-45deg);width:32px;height:32px}.villageQuestGivers .questGiver .questMarkerContent .questMarkerContentWrapper{border-top:1px none #9c5400;border-left:1px none #9c5400;z-index:-1}.villageQuestGivers .questGiver .questMarkerContent .questMarkerContentWrapper .questMarkerStatus{position:absolute;top:5px;right:6px;-webkit-filter:blur(0);-webkit-transform:translateZ(0)}.villageQuestGivers .questGiver .questMarkerContent .questMarkerContentWrapper .questMarkerStatus.character_exclamationMark_small,.villageQuestGivers .questGiver .questMarkerContent .questMarkerContentWrapper .questMarkerStatus.character_questionMark_small{top:7px;right:6px}.questDialogBG{position:absolute;top:0;right:0;background-image:url("../images_rtl/x.gif");width:1px;height:1px;width:100%;height:100%}@-webkit-keyframes tutorialArrowAni{from{-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);-o-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}65%{-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);-o-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}75%{-webkit-transform:translate3d(0,30px,0);-moz-transform:translate3d(0,30px,0);-ms-transform:translate3d(0,30px,0);-o-transform:translate3d(0,30px,0);transform:translate3d(0,30px,0)}85%{-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);-o-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}


[I] = R;

                if (!(I == 47) && !char.IsLetter(Upper[I]))
                {
                    S = TextGraphics.MeasureString(Upper[I].ToString(), Font);
                    UpperCache[I] = new PointF(R.X + (R.Width / 2 - S.Width / 2), R.Y + R.Height - S.Height - 2);

                    S = TextGraphics.MeasureString(Lower[I].ToString(), Font);
                    LowerCache[I] = new PointF(R.X + (R.Width / 2 - S.Width / 2), R.Y + R.Height - S.Height - 2);
                }
            }
        }

        Buttons[48] = new Rectangle(0, 4 * 32, 2 * 32, 32);
        Buttons[49] = new Rectangle(Buttons[48].Right, 4 * 32, 8 * 32, 32);
        Buttons[50] = new Rectangle(Buttons[49].Right, 4 * 32, 2 * 32, 32);
    }

    private GraphicsPath GP1;
    private SizeF SZ1;

    private PointF PT1;
    private Pen P1;
    private Pen P2;
    private Pen P3;

    private SolidBrush B1;
    private PathGradientBrush PB1;

    private LinearGradientBrush GB1;
    private Graphics G;
    protected override void OnPaint(System.Windows.Forms.PaintEventArgs e)
	{
		G = e.Graphics;
		G.TextRenderingHint = TextRenderingHint.ClearTypeGridFit;

		G.Clear(BackColor);

		Rectangle R = default(Rectangle);

		int Offset = 0;
		G.DrawRectangle(P1, 0, 0, (12 * 32) + 1, (5 * 32) + 1);

		for (int I = 0; I <= Buttons.Length - 1; I++) {
			R = Buttons[I];

			Offset = 0;
			if (I == Pressed) {
				Offset = 1;

				GP1 = new GraphicsPath();
				GP1.AddRectangle(R);

				PB1 = new PathGradientBrush(GP1);
				PB1.CenterColor = Color.FromArgb(60, 60, 60);
				PB1.SurroundColors = new Color[]{ Color.FromArgb(55, 55, 55) };
				PB1.FocusScales = new PointF(0.8f, 0.5f);

				G.FillPath(PB1, GP1);
			} else {
				GB1 = new LinearGradientBrush(R, Color.FromArgb(60, 60, 60), Color.FromArgb(55, 55, 55), 90f);
				G.FillRectangle(GB1, R);
			}

			switch (I) {
				case 48:
				case 49:
				case 50:
					SZ1 = G.MeasureString(Other[I - 48], Font);
					G.DrawString(Other[I - 48], Font, Brushes.Black, R.X + (R.Width / 2 - SZ1.Width / 2) + Offset + 1, R.Y + (R.Height / 2 - SZ1.Height / 2) + Offset + 1);
					G.DrawString(Other[I - 48], Font, Brushes.White, R.X + (R.Width / 2 - SZ1.Width / 2) + Offset, R.Y + (R.Height / 2 - SZ1.Height / 2) + Offset);
					break;
				case 47:
					DrawArrow(Color.Black, R.X + Offset + 1, R.Y + Offset + 1);
					DrawArrow(Color.White, R.X + Offset, R.Y + Offset);
					break;
				default:
					if (Shift) {
                        G.DrawString(Upper[I].ToString(), Font, Brushes.Black, R.X + 3 + Offset + 1, R.Y + 2 + Offset + 1);
                        G.DrawString(Upper[I].ToString(), Font, Brushes.White, R.X + 3 + Offset, R.Y + 2 + Offset);

						if (!char.IsLetter(Lower[I])) {
							PT1 = LowerCache[I];
                            G.DrawString(Lower[I].ToString(), Font, B1, PT1.X + Offset, PT


upportedEmulators[emulatorId]['hasMetadataSupport'],
        path: pathFromStorage ?? defaultPath.path,
      );
    } else if (emulatorId == 'ryujinx') {
      final String? pathFromStorage = await storage.get<String?>('ryujinxPath');
      final RyujinxFilesystem emulatorFilesystem = MMConfig.supportedEmulators[emulatorId]['filesystem'];
      final defaultPath = await emulatorFilesystem.defaultEmulatorAppDirectory();
      return Emulator(
        id: emulatorId,
        name: supportedEmulators[emulatorId]['name'],
        filesystem: supportedEmulators[emulatorId]['filesystem'],
        hasMetadataSupport: supportedEmulators[emulatorId]['hasMetadataSupport'],
        path: pathFromStorage ?? defaultPath.path,
      );
    }

    return null;
  }

  Future<Emulator?> evaluateEmulator(
    EmulatorRef ref,
    String? selectedEmulator,
    bool withCustomSelect,
  ) async {
    if (selectedEmulator != null) {
      // Create emulator object
      final emulator = await createEmulatorById(selectedEmulator);
      if (emulator != null) {
        // Check if default emulator application folder path is valid
        final bool isValid = await EmulatorService.instance.isValidEmulatorPath(emulator.id, emulator.path);
        if (isValid == false || withCustomSelect == true) {
          await updateEmulatorPathByUserSelection(emulator, ref);
        }

        return emulator;
      }
    }

    return null;
  }

  Future<void> updateEmulatorPathByUserSelection(Emulator emulator, EmulatorRef ref) async {
    // Try again by user selected path
    String? selectedPath = await FilePicker.platform.getDirectoryPath(
      dialogTitle: 'no_games_found_hint_text'.tr(namedArgs: {'emulatorName': emulator.name}),
      initialDirectory: (await emulator.filesystem.defaultEmulatorAppDirectory()).parent.path,
      lockParentWindow: true,
    );
    if (selectedPath != null) {
      if (await EmulatorService.instance.isValidEmulatorPath(emulator.id, selectedPath)) {
        // Save path to storage
        storage.set<String>('${emulator.id}Path', selectedPath);
        return;
      }
    }
  }
}
// GENERATED CODE - DO NOT MODIFY BY HAND

part of 'emulator.dart';

// **************************************************************************
// RiverpodGenerator
// **************************************************************************

String _$emulatorHash() => r'932ca6f76aba32bec532af98265c5bea186fbe49';

/// See also [emulator].
@ProviderFor(emulator)
final emulatorProvider = AutoDisposeFutureProvider<Emulator?>.internal(
  emulator,
  name: r'emulatorProvider',
  debugGetCreateSourceHash:
      const bool.fromEnvironment('dart.vm.product') ? null : _$emulatorHash,
  dependencies: null,
  allTransitiveDependencies: null,
);

typedef EmulatorRef = AutoDisposeFutureProviderRef<Emulator?>;
String _$selectedEmulatorHash() => r'1f5922e7cf17601cdefe98e9e53f081a3192dc27';

/// See also [SelectedEmulator].
@ProviderFor(SelectedEmulator)
final selectedEmulatorProvider =
    AutoDisposeAsyncNotifierProvider<SelectedEmulator, String?>.internal(
  SelectedEmulator.new,
  name: r'selectedEmulatorProvider',
  debugGetCreateSourceHash: const bool.fromEnvironment('dart.vm.product')
      ? null
      : _$selectedEmulatorHash,
  dependencies: null,
  allTransitiveDependencies: null,
);

typedef _$SelectedEmulator = AutoDisposeAsyncNotifier<String?>;
// ignore_for_file: unnecessary_raw_strings, subtype_of_sealed_class, invalid_use_of_internal_member,