tring();

  const getDelay = ({ index = 0, attemptsLeft = freeAttempts }: IDelayCofig = {}): ILimitInfo => (attemptsLeft > 0 ? ({
    delay: 0,
    attemptsLeft: attemptsLeft - 1,
    freeAttemptsUnlockTime: getFreeAttemptsReleaseTime()
  }) : ({
    delay: delays[index],
    attemptsLeft: 0,
    nextRequestTime: moment().add(delays[index], 'second').toISOString()
  }));

  const getSecondsDiff = (isoString = moment().toISOString()) => moment(isoString).diff(moment(), 'second');

  const continueRequest = async ({
    delayConfig = {},
    redisDelayKey,
    requestObject,
    nextFunction
  }: {
    delayConfig?: IDelayCofig,
    redisDelayKey: string,
    requestObject: express.Request,
    nextFunction: express.NextFunction
  }) => {
    const requestLimitInfo = getDelay(delayConfig);
    await setRedisValue(redisDelayKey, requestLimitInfo);
    Object.assign(requestObject, { delay: requestLimitInfo });
    return nextFunction();
  };

  const stopRequest = async ({
    redisDelayKey,
    delayInfo,
    responceObject
  }: {
    redisDelayKey: string,
    delayInfo: ILimitInfo,
    responceObject: express.Response
  }) => {
    await setRedisValue(redisDelayKey, delayInfo);
    return responceObject.status(429).send(delayInfo);
  };

  if (!redisDelay) {
    return continueRequest({
      redisDelayKey: redisKey,
      requestObject: request,
      nextFunction: next
    });
  }

  if (redisDelay.attemptsLeft > 0) {
    const secondsDiff = getSecondsDiff(redisDelay.freeAttemptsUnlockTime);

    return continueRequest({
      delayConfig: secondsDiff > 0 ? { attemptsLeft: redisDelay.attemptsLeft } : {},
      redisDelayKey: redisKey,
      requestObject: request,
      nextFunction: next
    });
  }

  if (redisDelay.nextRequestTime) {
    const secondsDiff = getSecondsDiff(redisDelay.nextRequestTime);
    if (secondsDiff < 0) {
      return continueRequest({
        redisDelayKey: redisKey,
        requestObject: request,
        nextFunction: next
      });
    }
  } else {
    return continueRequest({
      delayConfig: {
        attemptsLeft: 0
      },
      redisDelayKey: redisKey,
      requestObject: request,
      nextFunction: next
    });
  }

  const index = delays.findIndex((i) => i === redisDelay.delay);
  if ((index === -1 || index === delays.length - 1) && increaseByLimitReached) {
    const delay: ILimitInfo = {
      delay: redisDelay.delay + increaseByLimitReached,
      attemptsLeft: 0,
      nextRequestTime: moment().add(redisDelay.delay + increaseByLimitReached, 'second').toISOString()
    };

    return stopRequest({
      redisDelayKey: redisKey,
      delayInfo: delay,
      responceObject: responce
    });
  }
  const delay = getDelay({ index: index === delays.length - 1 ? index : index + 1, attemptsLeft: 0 });
  return stopRequest({
    redisDelayKey: redisKey,
    delayInfo: delay,
    responceObject: responce
  });
};

import { Product } from './Product';
import { Store } from './store';
import { Cappuccino } from './cappuccino';
import { Latte } from './latte';

export class CoffeeStore extends Store {
    constructor() {
        super();
    }

    protected createProduct(type: string): Product {
        if (type === 'latte') {
            return new Latte();
        } else if (type === 'Cappuccino') {
            return new Cappuccino();
        } else {
            return new Product();
        }


T_EVENT+RESETS_STANDARD-RESET_TURN_SET+RESET_PHASE+PHASE_END,0,1)
	Duel.SetOperationInfo(0,CATEGORY_POSITION,c,1,0,0)
end
function c75487237.operation(e,tp,eg,ep,ev,re,r,rp)
	local c=e:GetHandler()
	if c:IsRelateToEffect(e) and c:IsFaceup() then
		Duel.ChangePosition(c,POS_FACEDOWN_DEFENSE)
	end
end
function c75487237.negcon(e,tp,eg,ep,ev,re,r,rp)
	if re:IsActiveType(TYPE_SPELL) and re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then
		local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
		return tg:GetCount()==1 and tg:GetFirst()==e:GetHandler() and e:GetHandler():IsFacedown()
	else
		return false
	end
end
function c75487237.negop(e,tp,eg,ep,ev,re,r,rp)
	Duel.NegateActivation(ev)
	local c=e:GetHandler()
	if c:IsRelateToEffect(e) then
		Duel.ChangePosition(c,POS_FACEUP_DEFENSE)
	end
end


SlidersHorizontal)
    data object Share : ActionState(R.string.share, Phosphor.ShareNetwork)
    data object CancelPending : ActionState(R.string.pending, Phosphor.X)
    data object CancelConnecting : ActionState(R.string.connecting, Phosphor.X)
    data object CancelDownloading : ActionState(R.string.downloading, Phosphor.X)
    data object NoAction : ActionState(R.string.no_action_possible, Phosphor.X)
    data object Bookmark : ActionState(R.string.favorite_add, Phosphor.HeartStraight)
    data object Bookmarked : ActionState(R.string.favorite_remove, Phosphor.HeartStraightFill)
}

open class LinkType(
    val icon: ImageVector,
    val title: String,
    val link: Uri? = null,
)

class DonateType(donate: Donate, context: Context) : LinkType(
    icon = when (donate) {
        is Donate.Regular        -> Phosphor.CurrencyDollarSimple
        is Donate.Bitcoin        -> Phosphor.CurrencyBTC
        is Donate.Litecoin       -> Icon.IcDonateLitecoin
        is Donate.Liberapay      -> Icon.IcDonateLiberapay
        is Donate.OpenCollective -> Icon.IcDonateOpencollective
    },
    title = when (donate) {
        is Donate.Regular        -> context.getString(R.string.website)
        is Donate.Bitcoin        -> "Bitcoin"
        is Donate.Litecoin       -> "Litecoin"
        is Donate.Liberapay      -> "Liberapay"
        is Donate.OpenCollective -> "Open Collective"
    },
    link = when (donate) {
        is Donate.Regular        -> donate.url.toUri()
        is Donate.Bitcoin        -> "bitcoin:${donate.address}".toUri()
        is Donate.Litecoin       -> "litecoin:${donate.address}".toUri()
        is Donate.Liberapay      -> "https://liberapay.com/${donate.id}".toUri()
        is Donate.OpenCollective -> "https://opencollective.com/${donate.id}".toUri()
    }
)

data class Request(
    val id: Int,
    val installed: Boolean,
    val updates: Boolean,
    val updateCategory: UpdateCategory,
    val section: Section,
    val order: Order,
    val ascending: Boolean,
    val category: String,
    val filteredOutRepos: Set<String>,
    val filteredAntiFeatures: Set<String>,
    val filteredLicenses: Set<String>,
    val numberOfItems: Int = 0,
    val minSDK: Int = 0,
    val targetSDK: Int = 0,
) {
    companion object {
        val All: Request
            get() = Request(
                id = Source.AVAILABLE.ordinal,
                installed = false,
                updates = false,
                updateCategory = UpdateCategory.ALL,
                section = Section.All,
                order = Preferences[Preferences.Key.SortOrderExplore].order,
                ascending = Preferences[Preferences.Key.SortOrderAscendingExplore],
                category = Preferences[Preferences.Key.CategoriesFilterExplore],
                filteredOutRepos = Preferences[Preferences.Key.ReposFilterExplore],
                filteredAntiFeatures = Preferences[Preferences.Key.AntifeaturesFilterExplore],
                filteredLicenses = Preferences[Preferences.Key.LicensesFilterExplore],
                minSDK = Preferences[Preferences.Key.MinSDKExplore].ordinal,
                targetSDK = Preferences[Preferences.Key.TargetSDKExplore].ordinal,
            )

        val F


48.22,92.41]
step
label "Kill_8_Razorfen_Thronweavers"
kill 8 Razorfen Thornweaver##7874 |q 6626/2 |goto The Barrens 48.14,92.26
step
label "Kill_8_Death's_Head_Cultists"
kill 8 Death's Head Cultist##7872 |q 6626/3 |goto The Barrens 46.68,87.95
You can find more around [48.22,92.41] |notinsticky
step
Follow the path up |goto The Barrens 49.10,94.49
talk Myriam Moonsinger##12866
turnin A Host of Evil##6626 |goto The Barrens 49.01,94.94
step
Enter the Razorfen Downs Dungeon with Your Group |goto Razorfen Downs 0.00,0.00 < 500 |c |q 3636
step
Inside the Razorfen Downs Dungeon:
click Holding Pen
|tip It looks like a large wooden fence on the north side of The Murder Pens.
|tip Follow the path left along the north side of the dungeon to reach the Spiral of Thorns and eventually The Caller's Chamber.
|tip Continue through The Caller's Chamber to reach The Murder Pens and immediately go left.
|tip Be sure to clear each area of enemies as you go.
talk Belnistrasz##8516
|tip Inside the Holding Pen.
accept Scourge of the Downs##3523
step
Inside the Razorfen Downs Dungeon:
talk Belnistrasz##8516
|tip Inside the Holding Pen.
turnin Scourge of the Downs##3523
accept Extinguishing the Idol##3525
|tip This is an escort quest.
|tip Accepting this quest will automatically start the escort after a few seconds.
|tip All group members will need to accept it at the same time to avoid missing the quest.
step
Inside the Razorfen Downs Dungeon:
Follow and protect Belnistrasz
Kill the enemies that attack in waves
kill Plaguemaw the Rotting##7356
Escort Belnistrasz to the Quilboar's Idol |q 3525/1
step
Inside the Razorfen Downs Dungeon:
click Belnistrasz's Brazier
|tip It will be in the room where he was channeling.
turnin Extinguishing the Idol##3525
step
Inside the Razorfen Downs Dungeon:
kill Amnennar the Coldbringer##7358 |q 3636/1
|tip He is the last boss of the dungeon.
|tip Follow the left path out of the Belnistrasz escort room, then go right in the Spiral of Thorns and jump down.
|tip From here, go west and follow the path as it wraps up and around, eventually reaching Amnennar at the top.
step
Leave the Razorfen Downs Dungeon
Click Here to Continue |confirm |q 3636
step
Enter the building |goto Stormwind City 42.88,34.14 < 7 |walk
talk Archbishop Benedictus##1284
|tip Inside the building.
turnin Bring the Light##3636 |goto Stormwind City 39.58,27.26
]]
)
ZygorGuidesViewer:RegisterGuide(
  'Dungeon Guides\\Uldaman Quests',
  {
    image = ZGV.IMAGESDIR .. 'Uldaman',
    description = 'This guide will walk you through completing the Uldaman Quests.',
  },
  [[
step
Reach Level 38 |ding 38
|tip Use the Leveling guides to accomplish this.
step
Follow the path |goto Loch Modan 46.86,77.59 < 20 |only if walking
Kill Shadowforge enemies around this area
|tip You may need help with this.
|tip You can find more inside the cave.
collect Shattered Necklace##7666 |goto Badlands 45.10,12.01 |q 2198 |future
step
use the Shattered Necklace##7666
accept The Shattered Necklace##2198
step
talk Talvash del Kissel##6826
turnin The Shattered Necklace##2198 |goto Ironforge 36


import ctypes
import unittest
from ctypes import CDLL, c_int
from test.support import import_helper
_ctypes_test = import_helper.import_module("_ctypes_test")

class CHECKED(c_int):
    def _check_retval_(value):
        # Receives a CHECKED instance.
        return str(value.value)
    _check_retval_ = staticmethod(_check_retval_)

class Test(unittest.TestCase):
    def test_checkretval(self):
        dll = CDLL(_ctypes_test.__file__)
        self.assertEqual(42, dll._testfunc_p_p(42))

        dll._testfunc_p_p.restype = CHECKED
        self.assertEqual("42", dll._testfunc_p_p(42))

        dll._testfunc_p_p.restype = None
        self.assertEqual(None, dll._testfunc_p_p(42))

        del dll._testfunc_p_p.restype
        self.assertEqual(42, dll._testfunc_p_p(42))

    @unittest.skipUnless(hasattr(ctypes, 'oledll'),
                         'ctypes.oledll is required')
    def test_oledll(self):
        oleaut32 = ctypes.oledll.oleaut32
        self.assertRaises(OSError, oleaut32.CreateTypeLib2, 0, None, None)

if __name__ == "__main__":
    unittest.main()


                }));
    // Test Decoding
    for (TestCase testCase : testCases) {
      testCase.test();
    }
  }

  @Test
  public void testHandle() {
    TestCase testCase =
        TestCase.createNew(
            new int[] {128, 0, 1, 0, 0, 0, 10, 1, 0, 1},
            MetaUtils.TableBuilder.newBuilder()
                .name("t")
                .addColumn("pk", IntegerType.BIGINT, true, -1)
                .addColumn("c1", IntegerType.BIGINT, false, 10)
                .setPkHandle(true)
                .build(),
            new IntHandle(10000L),
            new Object[] {new IntHandle(10000L), 1L});
    testCase.test();
  }

  @Test
  public void testNullValues() {
    TestCase testCase =
        TestCase.createNew(
            new int[] {128, 0, 1, 0, 1, 0, 2, 1, 1, 0, 2},
            MetaUtils.TableBuilder.newBuilder()
                .name("t")
                .addColumn("c1", IntegerType.BIGINT)
                .addColumn("c2", IntegerType.BIGINT)
                .build(),
            new Object[] {null, 2L});
    testCase.test();
  }

  @Test
  public void testNewRowTypes() {
    // TODO: Enable JSON and Set type encoding
    MetaUtils.TableBuilder tableBuilder =
        MetaUtils.TableBuilder.newBuilder()
            .name("t")
            .addColumn("c1", IntegerType.BIGINT, 1)
            .addColumn("c2", IntegerType.SMALLINT, 22)
            .addColumn("c3", RealType.DOUBLE, 3)
            .addColumn("c4", BytesType.BLOB, 24)
            .addColumn("c5", StringType.CHAR, 25)
            .addColumn("c6", TimestampType.TIMESTAMP, 5)
            .addColumn("c7", TimeType.TIME, 16)
            .addColumn("c8", new DecimalType(6, 4), 8)
            .addColumn("c9", IntegerType.YEAR, 12)
            .addColumn("c10", TEST_ENUM_TYPE, 9)
            // .addColumn("c11", JsonType.JSON, 14)
            .addColumn("c12", UninitializedType.NULL, 11) // null
            .addColumn("c13", UninitializedType.NULL, 2) // null
            .addColumn("c14", UninitializedType.NULL, 100) // null
            .addColumn("c15", RealType.FLOAT, 116)
            // .addColumn("c16", TEST_SET_TYPE, 117)
            .addColumn("c17", TEST_BIT_TYPE, 118)
            .addColumn("c18", StringType.VAR_STRING, 119);
    TiTableInfo tbl = tableBuilder.build();
    Timestamp ts = new Timestamp(1320923471000L);
    ts.setNanos(999999000);
    TestCase testCase =
        TestCase.createNew(
            // new int[] {
            //   128, 0, 15, 0, 3, 0, 1, 3, 5, 8, 9, 12, 14, 16, 22, 24, 25, 116, 117, 118, 119, 2,
            // 11,
            //   100, 1, 0, 9, 0, 17, 0, 22, 0, 23, 0, 25, 0, 54, 0, 62, 0, 63, 0, 66, 0, 68, 0, 76,
            // 0,
            //   77, 0, 81, 0, 81, 0, 1, 192, 0, 0, 0, 0, 0, 0, 0, 63, 66, 15, 203, 178, 148, 138,
            // 25,
            //   6, 4, 139, 38, 172, 2, 207, 7, 1, 1, 0, 0, 0, 28, 0, 0, 0, 19, 0, 0, 0, 1, 0, 9,
            // 20,
            //   0, 0, 0, 97, 2, 0, 0, 0, 0, 0, 0, 0, 0, 128, 226, 194, 24


�托人的身份证明文件。授权委托书应当载明委托事项、权限和期限。申请人、第三人变更或者解除代理人权限的，应当书面告知行政复议机构。

第十八条 符合法律援助条件的行政复议申请人申请法律援助的，法律援助机构应当依法为其提供法律援助。

第十九条 公民、法人或者其他组织对行政行为不服申请行政复议的，作出行政行为的行政机关或者法律、法规、规章授权的组织是被申请人。

两个以上行政机关以共同的名义作出同一行政行为的，共同作出行政行为的行政机关是被申请人。

行政机关委托的组织作出行政行为的，委托的行政机关是被申请人。

作出行政行为的行政机关被撤销或者职权变更的，继续行使其职权的行政机关是被申请人。

### 第三节 申请的提出

第二十条 公民、法人或者其他组织认为行政行为侵犯其合法权益的，可以自知道或者应当知道该行政行为之日起六十日内提出行政复议申请；但是法律规定的申请期限超过六十日的除外。

因不可抗力或者其他正当理由耽误法定申请期限的，申请期限自障碍消除之日起继续计算。

行政机关作出行政行为时，未告知公民、法人或者其他组织申请行政复议的权利、行政复议机关和申请期限的，申请期限自公民、法人或者其他组织知道或者应当知道申请行政复议的权利、行政复议机关和申请期限之日起计算，但是自知道或者应当知道行政行为内容之日起最长不得超过一年。

第二十一条 因不动产提出的行政复议申请自行政行为作出之日起超过二十年，其他行政复议申请自行政行为作出之日起超过五年的，行政复议机关不予受理。

第二十二条 申请人申请行政复议，可以书面申请；书面申请有困难的，也可以口头申请。

书面申请的，可以通过邮寄或者行政复议机关指定的互联网渠道等方式提交行政复议申请书，也可以当面提交行政复议申请书。行政机关通过互联网渠道送达行政行为决定书的，应当同时提供提交行政复议申请书的互联网渠道。

口头申请的，行政复议机


�의 잿빛혓바닥 부적",
[32489] = "열정의 잿빛혓바닥 부적",
[32490] = "총명의 잿빛혓바닥 부적",
[32491] = "환영의 잿빛혓바닥 부적",
[32492] = "필살의 잿빛혓바닥 부적",
[32493] = "어둠의 잿빛혓바닥 부적",
[32494] = "파괴의 홀로그램 고글",
[32495] = "강력한 치유 렌즈 4000",
[32496] = "추억이 담긴 티란데의 기념품",
[32497] = "스톰레이지 인장 반지",
[32499] = "몬스터 - Mace2H, Ogri'la Hammer",
[32500] = "카라보르의 수정 돌기",
[32501] = "어둠달부족 휘장",
[32502] = "지옥 분비샘",
[32503] = "야르질의 양고기",
[32504] = "몬스터 - Silithid Claw (Offhand)",
[32505] = "배신자의 광기",
[32506] = "황천날개 알",
[32507] = "몬스터 - Polearm, Teron Gorefiend (Black Temple)",
[32508] = "심연의 목걸이",
[32509] = "황천날개 유물",
[32510] = "소리없는 추적의 장화",
[32512] = "로데론 전사자의 벨트",
[32513] = "성스러운 감화의 손목띠",
[32514] = "스케티스 고리",
[32515] = "결단의 손목보호대",
[32516] = "정화의 손목띠",
[32517] = "물결치유사의 어깨보호대",
[32518] = "변화하는 나뭇잎 덮개",
[32519] = "성스러운 인도의 벨트",
[32520] = "마나로 벼려낸 구슬",
[32521] = "불가침의 면갑",
[32522] = "악마의 보루방패",
[32523] = "이샤알의 연감",
[32524] = "귀족의 외투",
[32525] = "일리다리 대영주의 관",
[32526] = "황폐의 고리",
[32527] = "고대 지식의 반지",
[32528] = "축복받은 카라보르 반지


'];
const activeHobbies = ['hiking'];
// const activeHobbies = ['hiking', ...hobbies];

// object or array
// ... -> object 혹은 array 의 값들을 추출
activeHobbies.push(...hobbies);

console.log(activeHobbies);

// Object 복제하기

const person = {
    name: 'alex',
    age: 23
};

const copiedPerson = { ...person };
console.log(copiedPerson);/* eslint-disable @typescript-eslint/no-unsafe-member-access */
/* eslint-disable @typescript-eslint/no-unsafe-assignment */
import express from 'express';
import { calculateBmi } from './bmiCalculator';
import { calculateExercise } from './exerciseCalculator';

const app = express();
app.use(express.json());

interface exerciseReturnedValue {
  weight: number,
  height: number,
  bmi: string
}

app.get('/hello', (_req,res) => {
  res.send('Hello Full Stack!');
});

app.get('/bmi', (req,res) => {
  const { height, weight } = req.query;

  if(!isNaN(Number(height)) && !isNaN(Number(weight))){
    const returnedValue : exerciseReturnedValue = {
      weight: Number(weight),
      height: Number(height),
      bmi: calculateBmi(Number(height),Number(weight))
    };

    res.json(returnedValue);
  }else{
    res.status(400).json({error: "malformatted parameters"});
  }
});

app.post('/exercises', (req,res) => {
  const body = req.body;

  const target: number = body.target;
  const record: Array<number> = body.daily_exercises;

  if(!record || !target){
    res.status(400).json({error: "parameters missing"});
  }else if(isNaN(Number(target)) || !(record instanceof Array)){
    res.status(400).json({error: "malformatted parameters"});
  }else{
    res.json(calculateExercise(record, target));
  }
});

const PORT = 3000;

app.listen(PORT, ()=>{
  console.log(`Server running on port ${PORT}`);
});enum EffectTag {
	UPDATE,
	PLACEMENT,
	DELETION,
}

interface Props {
	[propName: string]: any;
	children: any[];
}

interface createdElement {
	type: string;
	props: Props;
}

interface createDom {
	(fiber: createdElement): HTMLElement | Text;
}

interface Deadline {
	didTimeout: boolean;
	timeRemaining: Function;
}

type Dom = createDom | HTMLElement | Text;

interface Fiber {
	type: string;
	props: Props;
	dom: Dom;
	parent: Fiber;
	child?: Fiber;
	sibling?: Fiber;
	alternate?: Fiber;
	effectTag: EffectTag;
	hooks?: any[];
}

type Didact = {
	createElement: Function;
	render: Function;
	useState: Function;
};

function createElement(
	type: string,
	props: object,
	...children: (object | string | number)[]
): createdElement {
	return {
		type,
		props: {
			...props,
			children: children.map((child: string | number | object) =>
				typeof child === "object" ? child : createTextElement(child)
			),
		},
	};
}

function createTextElement(text: string | number): object {
	return {
		type: "TEXT_ELEMENT",
		props: {
			nodeValue: text,
			children: [],
		},
	};
}

// changed in favor of concurrent mode
// function render(element: createdElement, container: HTMLElement | Text) {
// 	const dom =
// 		element.type == "TEXT_ELEMENT"
// 			? document.createTextNode("")
// 			: document.createElement(element.type);

// 	c


令
    search_parser = subparsers.add_parser('search', help='命令行搜索')
    search_parser.add_argument('query', help='搜索查询')
    search_parser.add_argument('--max-results', '-n', type=int, default=5, help='最大结果数')
    search_parser.add_argument('--threshold', '-t', type=float, default=0.3, help='相似度阈值')
    search_parser.add_argument('--hybrid', action='store_true', help='使用混合搜索')
    search_parser.add_argument('--llm', action='store_true', help='启用LLM分析')
    search_parser.add_argument('--quick', action='store_true', help='快速搜索模式')
    search_parser.add_argument('--refresh', action='store_true', help='刷新索引')
    search_parser.set_defaults(func=cmd_search)

    # 初始化命令
    init_parser = subparsers.add_parser('init', help='初始化搜索引擎')
    init_parser.add_argument('--force', '-f', action='store_true', help='强制重新初始化')
    init_parser.add_argument('--embedding-provider', choices=['local', 'openai', 'zhipu', 'qwen', 'baidu'], help='指定嵌入模型提供商')
    init_parser.set_defaults(func=cmd_init)

    # 配置命令
    config_parser = subparsers.add_parser('config', help='配置管理')
    config_parser.add_argument('--show', '-s', action='store_true', help='显示当前配置')
    config_parser.add_argument('--validate', action='store_true', help='验证配置')
    config_parser.add_argument('--clear-cache', action='store_true', help='清除缓存')
    config_parser.set_defaults(func=cmd_config)

    # 交互式命令
    interactive_parser = subparsers.add_parser('interactive', help='交互式搜索模式')
    interactive_parser.set_defaults(func=cmd_interactive)

    # 解析参数
    args = parser.parse_args()

    # 如果没有指定命令，显示帮助
    if not args.command:
        print_banner()
        print_config_status()
        print("\n💡 使用 'python main.py --help' 查看所有可用命令")
        print("   或者使用 'python main.py web' 启动Web界面")
        return

    # 设置日志级别
    if args.quiet:
        import logging
        logging.getLogger().setLevel(logging.ERROR)
    elif args.verbose:
        import logging
        logging.getLogger().setLevel(logging.DEBUG)

    # 执行命令
    try:
        if not args.quiet:
            print_banner()

        args.func(args)

    except KeyboardInterrupt:
        print("\n👋 程序已中断")
        sys.exit(0)
    except Exception as e:
        log_error(f"程序执行失败: {e}")
        if args.verbose:
            import traceback
            traceback.print_exc()
        else:
            print(f"❌ 程序执行失败: {e}")
        sys.exit(1)

if __name__ == '__main__':
    main()


_str().unwrap(),
                std::env::var_os("PKG_CONFIG_PATH")
                    .map(|v| String::from(v.to_str().unwrap()))
                    .unwrap_or_else(String::new)
            ),
        );
    }

    pkgconf.statik(cfg!(feature = "static"));
    pkgconf.cargo_metadata(false);
    for link_lib in pkgconf
        .probe(
            format!(
                "libcoap-3-{}",
                &dtls_backend
                    .as_ref()
                    .map(|v| v.to_string())
                    .unwrap_or_else(|| "notls".to_string())
            )
            .as_str(),
        )
        .unwrap()
        .libs
    {
        let link_lib = match link_lib.as_str() {
            ":libtinydtls.a" => String::from("tinydtls"),
            v => String::from(v),
        };
        println!(
            "cargo:rustc-link-lib={}{}",
            cfg!(feature = "static").then(|| "static=").unwrap_or(""),
            &link_lib
        );
    }

    bindgen_builder = bindgen_builder
        .header("src/wrapper.h")
        .parse_callbacks(Box::new(bindgen::CargoCallbacks))
        .default_enum_style(EnumVariation::Rust { non_exhaustive: true })
        .rustfmt_bindings(false)
        // Causes invalid syntax for some reason, so we have to disable it.
        .generate_comments(false)
        .dynamic_link_require_all(true)
        .allowlist_function("coap_.*")
        .allowlist_type("coap_.*")
        .allowlist_var("coap_.*")
        .allowlist_function("COAP_.*")
        .allowlist_type("COAP_.*")
        .allowlist_var("COAP_.*")
        // We use the definitions made by the libc crate instead
        .blocklist_type("sockaddr(_in|_in6)?")
        .blocklist_type("in6?_(addr|port)(_t)?")
        .blocklist_type("epoll_event")
        .blocklist_type("in6_addr__bindgen_ty_1")
        .blocklist_type("(__)?socklen_t")
        .blocklist_type("fd_set")
        .blocklist_type("sa_family_t")
        .blocklist_type("(__)?time_t")
        .blocklist_type("__fd_mask")
        // Are generated because they are typedef-ed inside of the C headers, blocklisting them
        // will instead replace them with the appropriate rust types.
        // See https://github.com/rust-lang/rust-bindgen/issues/1215 for an open issue concerning
        // this problem.
        .blocklist_type("__(u)?int(8|16|32|64|128)_t")
        .size_t_is_usize(true);
    let bindings = bindgen_builder.generate().unwrap();

    let out_path = PathBuf::from(env::var("OUT_DIR").unwrap());
    bindings.write_to_file(out_path.join("bindings.rs")).unwrap();
}
use colored::*;

#[allow(dead_code)]
pub fn get_extension(path: String) -> String {
    let path_name: Vec<&str> = path.split('.').collect::<Vec<&str>>();

    let extension: &str


C) 2019. Uber Technologies
 *
 * 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
 *
 *     https://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 autodispose2.lint

import com.android.tools.lint.client.api.JavaEvaluator
import com.android.tools.lint.client.api.UElementHandler
import com.android.tools.lint.detector.api.Category
import com.android.tools.lint.detector.api.Context
import com.android.tools.lint.detector.api.Detector
import com.android.tools.lint.detector.api.Implementation
import com.android.tools.lint.detector.api.Issue
import com.android.tools.lint.detector.api.JavaContext
import com.android.tools.lint.detector.api.Scope
import com.android.tools.lint.detector.api.Severity
import com.android.tools.lint.detector.api.SourceCodeScanner
import com.android.tools.lint.detector.api.UImplicitCallExpression
import com.android.tools.lint.detector.api.isJava
import com.android.tools.lint.detector.api.isKotlin
import com.intellij.psi.PsiMethod
import com.intellij.psi.PsiSynchronizedStatement
import com.intellij.psi.PsiType
import com.intellij.psi.util.PsiUtil
import java.io.StringReader
import java.util.EnumSet
import java.util.Properties
import org.jetbrains.uast.UAnnotationMethod
import org.jetbrains.uast.UBlockExpression
import org.jetbrains.uast.UCallExpression
import org.jetbrains.uast.UCallableReferenceExpression
import org.jetbrains.uast.UClassInitializer
import org.jetbrains.uast.UElement
import org.jetbrains.uast.UExpression
import org.jetbrains.uast.UIfExpression
import org.jetbrains.uast.ULambdaExpression
import org.jetbrains.uast.UMethod
import org.jetbrains.uast.UParenthesizedExpression
import org.jetbrains.uast.UQualifiedReferenceExpression
import org.jetbrains.uast.USwitchClauseExpressionWithBody
import org.jetbrains.uast.USwitchExpression
import org.jetbrains.uast.UYieldExpression
import org.jetbrains.uast.getContainingUClass
import org.jetbrains.uast.getParentOfType
import org.jetbrains.uast.skipParenthesizedExprUp
import org.jetbrains.uast.visitor.AbstractUastVisitor

internal const val CUSTOM_SCOPE_KEY = "autodispose.typesWithScope"
internal const val LENIENT = "autodispose.lenient"
internal const val OVERRIDE_SCOPES = "autodispose.overrideScopes"
internal const val KOTLIN_EXTENSION_FUNCTIONS = "autodispose.kotlinExtensionFunctions"

/** Detector which checks if your stream subscriptions are handled by AutoDispose. */
public class AutoDisposeDetector : Detector(), SourceCodeScanner {

  internal companion object {
    internal const val LINT_DESCRIPTION =
      "Missing Disposable handling: Apply AutoDispose or cache " +
        "the Disposable instance manually and enable lenient mode."

    internal val ISSUE: Issue =
      Issue.create(
        "AutoDispose",
        LINT_DESCRIPTION,
        "You're subscribing to an observable but not handling its subscription. This " +
          "can result in memory leaks. You can avoid memory leaks by appending " +
          "`.as(autoDispo


     *     // Do context-independent logic such as logging
     * }
     * ```
     */
    public abstract override val immediate: HandlerDispatcher
}

internal class AndroidDispatcherFactory : MainDispatcherFactory {

    override fun createDispatcher(allFactories: List<MainDispatcherFactory>): MainCoroutineDispatcher {
        val mainLooper = Looper.getMainLooper() ?: throw IllegalStateException("The main looper is not available")
        return HandlerContext(mainLooper.asHandler(async = true))
    }

    override fun hintOnError(): String = "For tests Dispatchers.setMain from kotlinx-coroutines-test module can be used"

    override val loadPriority: Int
        get() = Int.MAX_VALUE / 2
}

/**
 * Represents an arbitrary [Handler] as an implementation of [CoroutineDispatcher]
 * with an optional [name] for nicer debugging
 *
 * ## Rejected execution
 *
 * If the underlying handler is closed and its message-scheduling methods start to return `false` on
 * an attempt to submit a continuation task to the resulting dispatcher,
 * then the [Job] of the affected task is [cancelled][Job.cancel] and the task is submitted to the
 * [Dispatchers.IO], so that the affected coroutine can cleanup its resources and promptly complete.
 */
@JvmName("from") // this is for a nice Java API, see issue #255
@JvmOverloads
public fun Handler.asCoroutineDispatcher(name: String? = null): HandlerDispatcher =
    HandlerContext(this, name)

private const val MAX_DELAY = Long.MAX_VALUE / 2 // cannot delay for too long on Android

@VisibleForTesting
internal fun Looper.asHandler(async: Boolean): Handler {
    // Async support was added in API 16.
    if (!async || Build.VERSION.SDK_INT < 16) {
        return Handler(this)
    }

    if (Build.VERSION.SDK_INT >= 28) {
        // TODO compile against API 28 so this can be invoked without reflection.
        val factoryMethod = Handler::class.java.getDeclaredMethod("createAsync", Looper::class.java)
        return factoryMethod.invoke(null, this) as Handler
    }

    val constructor: Constructor<Handler>
    try {
        constructor = Handler::class.java.getDeclaredConstructor(Looper::class.java,
            Handler.Callback::class.java, Boolean::class.javaPrimitiveType)
    } catch (ignored: NoSuchMethodException) {
        // Hidden constructor absent. Fall back to non-async constructor.
        return Handler(this)
    }
    return constructor.newInstance(this, null, true)
}

@JvmField
@Deprecated("Use Dispatchers.Main instead", level = DeprecationLevel.HIDDEN)
internal val Main: HandlerDispatcher? = runCatching { HandlerContext(Looper.getMainLooper().asHandler(async = true)) }.getOrNull()

/**
 * Implements [CoroutineDispatcher] on top of an arbitrary Android [Handler].
 */
internal class HandlerContext private constructor(
    private val handler: Handler,
    private val name: String?,
    private val invokeImmediately: Boolean
) : HandlerDispatcher(), Delay {
    /**
     * Creates [CoroutineDispatcher] for the given Android [handler].
     *
     * @param handler a handler.
     * @param name an optional name for debugging.
     */
    constructor(
        handler: Handler,
        name: String? = null
    ) : this(handler, name, false)

    override val immediate: HandlerContext = if (invokeImmediately) this else
        HandlerContext(handler, name, true)

    override fun isDispatchNeeded(context: CoroutineContext): Boolean {
        return !invokeImmediately || Looper.myLooper() != handler.looper
    }

    override fun dispatch(context: CoroutineContext, block: Runnable) {
        if (!handler.post(block)) {
            cancelOnRejection(context, block)
        }
    }

    override fun scheduleResum


is prismatic joint

E.isprismatic is true if the transform element is a joint, that is, its
parameter is of the form 'qN' and it controls a translation.

ETS2.mtimes

Compound transforms

E1 * E2 is a sequence of two elementary transform.

See also

ETS2.plus

ETS2.n

Number of joints in transform sequence

E.njoints is the number of joints in the transform sequence.

Notes

Is a wrapper on njoints, for compatibility with SerialLink object.

See also

ETS2.n

ETS2.njoints

Number of joints in transform sequence

E.njoints is the number of joints in the transform sequence.

See also

ETS2.n

ETS2.plot

Graphical display and animation

ETS.plot(q, options) displays a graphical animation of a robot based on
the transform sequence.  Constant translations are represented as pipe segments, rotational joints as cylinder, and
prismatic joints as boxes. The robot is displayed at the joint angle q (1xN), or
if a matrix (MxN) it is animated as the robot moves along the M-point trajectory.

Options

'workspace',  W	 Size of robot 3D workspace, W = [xmn, xmx ymn ymx zmn zmx]

'floorlevel', L	 Z-coordinate of floor (default -1)

'delay', D	 Delay betwen frames for animation (s)

'fps', fps	 Number of frames per second for display, inverse of 'delay' option

 '[no]loop'	 Loop over the trajectory forever

 '[no]raise'	 Autoraise the figure

'movie', M	 Save an animation to the movie M

'trail', L	 Draw a line recording the tip path, with line style L

<td


_2261c9a - 2
.hword branch_2261d0a - Jumppoints_2261c9a - 2
.hword branch_2261d26 - Jumppoints_2261c9a - 2
.hword branch_2261d6a - Jumppoints_2261c9a - 2
.hword branch_2261dc0 - Jumppoints_2261c9a - 2
.thumb
branch_2261ca8: @ 2261ca8 :thumb
	mov     r2, r4
	add     r2, #0xdc
	ldr     r1, [sp, #0xc]
	ldr     r2, [r2, #0x0]
	mov     r0, r7
	bl      Function_2261474
	mov     r1, r6
	add     r1, #0xc0
	ldr     r0, [sp, #0x8]
	ldr     r1, [r1, #0x0]
	bl      Function_2017240
	b       branch_2261df4
@ 0x2261cc4

.thumb
branch_2261cc4: @ 2261cc4 :thumb
	mov     r2, r4
	add     r2, #0xdc
	ldr     r1, [sp, #0xc]
	ldr     r2, [r2, #0x0]
	mov     r0, r7
	bl      Function_2261498
	mov     r1, r6
	add     r1, #0xc0
	str     r0, [sp, #0x14]
	ldr     r0, [sp, #0x8]
	ldr     r1, [r1, #0x0]
	bl      Function_2017240
	ldr     r0, [sp, #0x14]
	cmp     r0, #0x1
	beq     branch_2261ce8
.thumb
branch_2261ce6: @ 2261ce6 :thumb
	b       branch_2261df4
@ 0x2261ce8

.thumb
branch_2261ce8: @ 2261ce8 :thumb
	mov     r0, r6
	add     r0, #0xd0
	ldr     r0, [r0, #0x0]
	mov     r1, r4
	str     r0, [sp, #0x10]
	ldr     r0, [sp, #0x0]
	mov     r2, r5
	bl      Function_2261220
	ldr     r0, [sp, #0x10]
	cmp     r0, #0x0
	beq     branch_2261df4
	ldr     r0, [sp, #0x0]
	ldr     r2, [sp, #0x10]
	mov     r1, r4
	blx     r2
	b       branch_2261df4
@ 0x2261d0a

.thumb
branch_2261d0a: @ 2261d0a :thumb
	mov     r2, r4
	add     r2, #0xdc
	ldr     r1, [sp, #0xc]
	ldr     r2, [r2, #0x0]
	mov     r0, r7
	bl      Function_22614c0
	mov     r1, r6
	add     r1, #0xc0
	ldr     r0, [sp, #0x8]
	ldr     r1, [r1, #0x0]
	bl      Function_2017240
	b       branch_2261df4
@ 0x2261d26

.thumb
branch_2261d26: @ 2261d26 :thumb
	mov     r2, r4
	add     r2, #0xdc
	ldr     r1, [sp, #0xc]
	ldr     r2, [r2, #0x0]
	mov     r0,


/*
 * Copyright (c) 2013 Johannes Berg <johannes@sipsolutions.net>
 *
 *  This file is free software: you may copy, redistribute and/or modify it
 *  under the terms of the GNU General Public License as published by the
 *  Free Software Foundation, either version 2 of the License, or (at your
 *  option) any later version.
 *
 *  This file is distributed in the hope that it will be useful, but
 *  WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 *  General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 * This file incorporates work covered by the following copyright and
 * permission notice:
 *
 * Copyright (c) 2012 Qualcomm Atheros, Inc.
 *
 * Permission to use, copy, modify, and/or distribute this software for any
 * purpose with or without fee is hereby granted, provided that the above
 * copyright notice and this permission notice appear in all copies.
 *
 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 */

#ifndef _ALX_H_
#define _ALX_H_

#include <linux/types.h>
#include <linux/etherdevice.h>
#include <linux/dma-mapping.h>
#include <linux/spinlock.h>
#include "hw.h"

#define ALX_WATCHDOG_TIME   (5 * HZ)

struct alx_buffer {
	struct sk_buff *skb;
	DEFINE_DMA_UNMAP_ADDR(dma);
	DEFINE_DMA_UNMAP_LEN(size);
};

struct alx_rx_queue {
	struct alx_rrd *rrd;
	dma_addr_t rrd_dma;

	struct alx_rfd *rfd;
	dma_addr_t rfd_dma;

	struct alx_buffer *bufs;

	u16 write_idx, read_idx;
	u16 rrd_read_idx;
};
#define ALX_RX_ALLOC_THRESH	32

struct alx_tx_queue {
	struct alx_txd *tpd;
	dma_addr_t tpd_dma;
	struct alx_buffer *bufs;
	u16 write_idx, read_idx;
};

#define ALX_DEFAULT_TX_WORK 128

enum alx_device_quirks {
	ALX_DEV_QUIRK_MSI_INTX_DISABLE_BUG = BIT(0),
};

struct alx_priv {
	struct net_device *dev;

	struct alx_hw hw;

	/* all descriptor memory */
	struct {
		dma_addr_t dma;
		void *virt;
		int size;
	} descmem;

	/* protect int_mask updates */
	spinlock_t irq_lock;
	u32 int_mask;

	int tx_ringsz;
	int rx_ringsz;
	int rxbuf_size;

	struct napi_struct napi;
	struct alx_tx_queue txq;
	struct alx_rx_queue rxq;

	struct work_struct link_check_wk;
	struct work_struct reset_wk;

	u16 msg_enable;

	bool msi;
};

extern const struct ethtool_ops alx_ethtool_ops;
extern const char alx_drv_name[];

#endif


namespace ReforgerServerApp.Components
{
    partial class AdvancedServerParameterSchedule
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }

        #region Component Designer generated code

        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            label1 = new Label();
            parameterValue = new NumericUpDown();
            timeUnit = new ComboBox();
            ((System.ComponentModel.ISupportInitialize) parameterValue).BeginInit();
            SuspendLayout();
            //
            // label1
            //
            label1.AutoSize = true;
            label1.Font = new Font("Segoe UI", 9F, FontStyle.Bold, GraphicsUnit.Point);
            label1.Location = new Point(4, 35);
            label1.Name = "


    "💡 开源社区的三重标准？",
    "• 国际开发者用 GitHub 建生态",
    "• 国内用户用 GitHub 传代码",
    "• 国内平台用 GitHub 赚热度",
    "",
    "📣 最后一句话：",
    "**GitHub 有两个入口，一个是全球协作的窗口，一个是国内数据的围墙——你以为你打开的是同一个网站，其实你身处两个世界。**"
  ]
},
{
  "id": 54,
  "title": "中国程序员为何最终都搬回 GitHub.com？",
  "summary": "从 Gitee 到极狐，从码云到镜像站，国产平台看似“更懂中国程序员”，但为什么最后大家还是默默翻墙回 GitHub.com？原因其实很简单：这里有代码，而那里有真正的开源。",
  "date": "2024-09-30",
  "readTime": 6,
  "tags": ["GitHub", "国产平台", "Gitee", "开源生态", "社区文化"],
  "content": [
    "🏃 很多中国程序员都有过这样一段‘迁移史’：",
    "• 一开始用 GitHub，因访问慢、打不开、被墙转向国内平台",
    "• 后来用 Gitee、极狐 GitLab、开源中国等国产平台",
    "• 再后来……他们又默默搬回了 GitHub.com",
    "",
    "📦 为什么搬走？五个字：受够了。",
    "",
    "🔇 1. 社区没声音",
    "• Issue 发出去像进了黑洞，没人回复",
    "• PR 提交之后几个月无人处理",
    "• 提个 Bug，只能加QQ群，群里还得先改昵称 + 报公司",
    "",
    "📄 2. 镜像而已，不是真社区",
    "• 很多国产平台项目是 GitHub 镜像：代码同步，交流断流",
    "• Pull Request 被禁用，或者只读不可 Fork",
    "• GitHub 有项目主页、看板、讨论，国产站只有 README",
    "",
    "📵 3. 审核 + 限制 = 不自由",
    "• 关键词审查，内容提交失败",
    "• 某日醒来，项目被锁仓库：“违反社区规则，详情请联系管理员”",
    "• 网页随时 502、403、被强制下线，无预警无恢复",
    "",
    "🐢 4. 功能滞后，接口兼容差",
    "• CI/CD 整合难，插件生态小，自动化构建不如 GitHub Actions 稳定",
    "• API 接口文档少，OAuth 授权有坑，二次开发受限",
    "


tils.SessionS, err.Error(), cgrEv, runID))
				withErrors = true
			}
			rply.StatQueueIDs[runID] = sIDs
		}
	}

	if argsFlagsWithParams.GetBool(utils.MetaSTIRAuthenticate) {
		for _, cgrEv := range getDerivedEvents(events, argsFlagsWithParams[utils.MetaSTIRAuthenticate].Has(utils.MetaDerivedReply)) {
			ev := engine.MapEvent(cgrEv.Event)
			opts := engine.MapEvent(cgrEv.APIOpts)
			attest := sS.cgrCfg.SessionSCfg().STIRCfg.AllowedAttest
			if uattest := opts.GetStringIgnoreErrors(utils.OptsStirATest); uattest != utils.EmptyString {
				attest = utils.NewStringSet(strings.Split(uattest, utils.InfieldSep))
			}
			var stirMaxDur time.Duration
			if stirMaxDur, err = opts.GetDuration(utils.OptsStirPayloadMaxDuration); err != nil {
				stirMaxDur = sS.cgrCfg.SessionSCfg().STIRCfg.PayloadMaxduration
			}
			if err = AuthStirShaken(opts.GetStringIgnoreErrors(utils.OptsStirIdentity),
				utils.FirstNonEmpty(opts.GetStringIgnoreErrors(utils.OptsStirOriginatorTn), ev.GetStringIgnoreErrors(utils.AccountField)),
				opts.GetStringIgnoreErrors(utils.OptsStirOriginatorURI),
				utils.FirstNonEmpty(opts.GetStringIgnoreErrors(utils.OptsStirDestinationTn), ev.GetStringIgnoreErrors(utils.Destination)),
				opts.GetStringIgnoreErrors(utils.OptsStirDestinationURI),
				attest, stirMaxDur); err != nil {
				return utils.NewSTIRError(err.Error())
			}
		}
	} else if argsFlagsWithParams.GetBool(utils.MetaSTIRInitiate) {
		rply.STIRIdentity = make(map[string]string)
		for runID, cgrEv := range getDerivedEvents(events, argsFlagsWithParams[utils.MetaSTIRInitiate].Has(utils.MetaDerivedReply)) {
			ev := engine.MapEvent(cgrEv.Event)
			opts := engine.MapEvent(cgrEv.APIOpts)
			attest := sS.cgrCfg.SessionSCfg().STIRCfg.DefaultAttest
			if uattest := opts.GetStringIgnoreErrors(utils.OptsStirATest); uattest != utils.EmptyString {
				attest = uattest
			}

			destURI := opts.GetStringIgnoreErrors(utils.OptsStirDestinationTn)
			destTn := utils.FirstNonEmpty(opts.GetStringIgnoreErrors(utils.OptsStirDestinationTn), ev.GetStringIgnoreErrors(utils.Destination))

			dest := utils.NewPASSporTDestinationsIdentity(strings.Split(destTn, utils.InfieldSep), strings.Split(destURI, utils.InfieldSep))

			var orig *utils.PASSporTOriginsIdentity
			if origURI := opts.GetStringIgnoreErrors(utils.OptsStirOriginatorURI); origURI != utils.EmptyString {
				orig = utils.NewPASSporTOriginsIdentity(utils.EmptyString, origURI)
			} else {
				orig = utils.NewPASSporTOriginsIdentity(
					utils.FirstNonEmpty(opts.GetStringIgnoreErrors(utils.OptsStirOriginatorTn),
						ev.GetStringIgnoreErrors(utils.AccountField)),
					utils.EmptyString)
			}
			pubkeyPath := utils.FirstNonEmpty(opts.GetStringIgnoreErrors(utils.OptsStirPublicKeyPath), sS.cgrCfg.SessionSCfg().STIRCfg.PublicKeyPath)
			prvkeyPath := utils.FirstNonEmpty(opts.GetStringIgnoreErrors(utils.OptsStirPrivateKeyPath), sS.cgrCfg.SessionSCfg().STIRCfg.PrivateKeyPath)

			payload := utils.New


4, 1538.0),
	City::new(1890, "Cameroon", "Fontem", 5.4666667, 9.8833332, 1342.0),
	City::new(1891, "Cameroon", "Mbanga", 4.5091667, 9.5680552, 154.0),
	City::new(1892, "Cameroon", "Banyo", 6.7500000, 11.8166666, 1260.0),
	City::new(1893, "Cameroon", "Manjo", 4.8452778, 9.8247223, 579.0),
	City::new(1894, "Cameroon", "Melong", 5.1166667, 9.9499998, 762.0),
	City::new(1895, "Cameroon", "Tibati", 6.4666667, 12.6333332, 840.0),
	City::new(1896, "Cameroon", "Muyuka", 4.2972222, 9.4055557, 54.0),
	City::new(1897, "Cameroon", "Obala", 4.1666667, 11.5333328, 528.0),
	City::new(1898, "Cameroon", "<NAME>", 4.6833333, 12.3666668, 632.0),
	City::new(1899, "Cameroon", "Penja", 4.6363889, 9.6819448, 151.0),
	City::new(1900, "Cameroon", "Mbandjok", 4.4500000, 11.8999996, 517.0),
	City::new(1901, "Cameroon", "Kaele", 10.1091667, 14.4508333, 371.0),
	City::new(1902, "Cameroon", "Bamusso", 4.4333333, 8.8999996, 1.0),
	City::new(1903, "Cameroon", "Lagdo", 9.0500000, 13.7333336, 188.0),
	City::new(1904, "Cameroon", "Tchollire", 8.4000000, 14.1666670, 376.0),
	City::new(1905, "Cameroon", "Belabo", 4.9333333, 13.3000002, 611.0),
	City::new(1906, "Cameroon", "Lolodorf", 3.2333333, 10.7333336, 406.0),
	City::new(1907, "Cameroon", "Eseka", 3.6500000, 10.7666664, 246.0),
	City::new(1908, "Cameroon", "Mamfe", 5.7666667, 9.2833328, 444.0),
	City::new(1909, "Cameroon", "Dizangue", 3.7666667, 9.9833336, 1.0),
	City::new(1910, "Cameroon", "Idenao", 4.2475000, 9.0047226, 127.0),
	City::new(1911, "Cameroon", "Akonolinga", 3.7666667, 12.2500000, 521.0),
	City::new(1912, "Cameroon", "Bogo", 10.7361111, 14.6108332, 341.0),
	City::new(1913, "Cameroon", "Tonga", 4.9666667, 10.6999998, 788.0),
	City::new(1914, "Cameroon", "<NAME>", 3.9833333, 13.1833334, 708.0),
	City::new(1915, "Cameroon", "Yokadouma", 3.5166667, 15.0500002, 562.0),
	City::new(1916, "Cameroon", "Bazou", 5.0666667, 10.4666672, 1218.0),
	City::new(1917, "Cameroon", "Mundemba", 4.9500000, 8.8666668, 322.0),
	City::new(1918, "Cameroon", "<NAME>", 5.6000000,


------------
  //
  // -----------------------------------------------------------------------------
  void setEditorData(QWidget* editor, const QModelIndex& index) const
  {
    qint32 col = index.column();
    if(col < SGODFTableModel::ColumnCount)
    {
      QLineEdit* lineEdit = qobject_cast<QLineEdit*>(editor);
      Q_ASSERT(lineEdit);
      lineEdit->setText(index.model()->data(index).toString());
    }
    else
    {
      QStyledItemDelegate::setEditorData(editor, index);
    }
  }

  // -----------------------------------------------------------------------------
  //
  // -----------------------------------------------------------------------------
  void setModelData(QWidget* editor, QAbstractItemModel* model, const QModelIndex& index) const
  {
    qint32 col = index.column();
    if(col < SGODFTableModel::ColumnCount)
    {
      QLineEdit* lineEdit = qobject_cast<QLineEdit*>(editor);
      Q_ASSERT(lineEdit);
      bool ok = false;
      double v = lineEdit->text().toFloat(&ok);
      model->setData(index, v);
    }
    else
    {
      QStyledItemDelegate::setModelData(editor, model, index);
    }
  }

private:
  QModelIndex m_Index;
  unsigned int m_CrystalStructure;
};


s://raw.githubusercontent.com/GMyhf/img/main/img/2811_1-20230909225323102.jpg)

在上图中，左边矩阵中用X标记的按钮表示被按下，右边的矩阵表示灯状态的改变。对矩阵中的每盏灯设置一个初始状态。请你按按钮，直至每一盏等都熄灭。与一盏灯毗邻的多个按钮被按下时，一个操作会抵消另一次操作的结果。在下图中，第2行第3、5列的按钮都被按下，因此第2行、第4列的灯的状态就不改变。

![img](https://raw.githubusercontent.com/GMyhf/img/main/img/2811_2-20230909225341954.jpg)

请你写一个程序，确定需要按下哪些按钮，恰好使得所有的灯都熄灭。根据上面的规则，我们知道

1）第2次按下同一个按钮时，将抵消第1次按下时所产生的结果。因此，每个按钮最多只需要按下一次；

2）各个按钮被按下的顺序对最终的结果没有影响；

3）对第1行中每盏点亮的灯，按下第2行对应的按钮，就可以熄灭第1行的全部灯。如此重复下去，可以熄灭第1、2、3、4行的全部灯。同样，按下第1、2、3、4、5列的按钮，可以熄灭前5列的灯。

**输入**

5行组成，每一行包括6个数字（0或1）。相邻两个数字之间用单个空格隔开。0表示灯的初始状态是熄灭的，1表示灯的初始状态是点亮的。

**输出**

5行组成，每一行包括6个数字（0或1）。相邻两个数字之间用单个空格隔开。其中的1表示需要把对应的按钮按下，0则表示不需要按对应的按钮。

样例输入

```
0 1 1 0 1 0
1 0 0 1 1 1
0 0 1 0 0 1
1 0 0 1 0 1
0 1 1 1 0 0
```

样例输出

```
1 0 1 0 0 1
1 1 0 1 0 1
0 0 1 0 1 1
1 0 0 1 0 0
0 1 0 0 0 0
```

2020fall-cs101，曲诤博。题本来是很难的，还好题干中给了提示，最后的难点有两个，一个是如何生成 0，1 排列组合的所有 64 个 list，这里我用了迭代的方法，还有一个就是如何实现题干的方法，这里用了一下深拷贝，之后就没啥问题了。

2020fall-cs101，顾臻宜。解题思路：A 记开关实时亮暗，B记开关操作与否。一旦确定第1 行的操作，剩
余第2、3、4、5 行的操作就确定；枚举第1 行（共2^6^=64 种可能）。
小知识：二维数组需要深度拷贝：import copy；A=copy.deepcopy(X)。

```python
X = [[0,0,0,0,0,0,0,0]]
Y = [[0,0,0,0,0,0,0,0]]
for _ in range(5):
    X.append([0] + [int(x)


বুটেরিন, জুয়ান বেনেটের সাথে বিকেন্দ্রীভূত সামাজিক মিডিয়ার ভবিষ্যত](https://www.youtube.com/watch?v=DTxE9KV3YrE) — _ETHGlobal_

### কমিউনিটিগুলো {#communities}

- [Status Discord সার্ভার](https://discord.com/invite/3Exux7Y)
- [Mirror Discord সার্ভার](https://discord.com/invite/txuCHcE8wV)
- [r/CryptoCurrency সাব-রেড্ডিট](https://www.reddit.com/r/CryptoCurrency/)
---
title: স্টেকিং উইথড্রয়াল
description: স্টেকিং পুশ উত্তোলন কি, সেগুলি কীভাবে কাজ করে এবং সেগুলোর জন্য পুরষ্কার পেতে স্টেকদের কী করতে হবে তার সংক্ষিপ্ত বিবরণীর পেজ
lang: bn
template: staking
image: /images/staking/leslie-withdrawal.png
alt: Leslie the rhino তার স্টেকিং পুরষ্কার সহ
sidebarDepth: 2
summaryPoints:
  - Shanghai/Capella আপগ্রেড ইথেরিয়াম-এ স্টেকিং প্রত্যাহার সক্ষম করেছে
  - ভ্যালিডেটর অপারেটরদের অবশ্যই একটি উত্তোলনের ঠিকানা প্রদান করতে হবে
  - পুরস্কার স্বয়ংক্রিয়ভাবে কয়েক দিন পর পর বিতরণ করা হয়
  - যেসকল ভ্যালিডেটররা সম্পূর্ণরূপে স্টেকিং থেকে প্রস্থান করে তারা তাদের অবশিষ্ট ব্যালেন্স পাবেন
---

<UpgradeStatus dateKey="page-staking-withdrawals-when">
12 এপ্রিল, 2023-এ ঘটে যাওয়া Shanghai/Capella আপগ্রেডের মাধ্যমে স্টেকিং উত্তোলনের ব্যবস্থা সক্ষম করা হয়ে�


"""Constants for cert_expiry tests."""
PORT = 443
HOST = "example.com"


age": "pong", "status": delays.status()}
        case "shutdown":  # клиент завершает работу
            host = host_db.get(device_hash)
            if host is None:
                return get_error(4, "unknown device")
            host.shutdown()
            return {"message": 0}
        case _:
            return get_error(4, "act")

# Обработка данных после отправки формы
@app.route('/admin', methods=['POST'])
def login():
    user = None
    auth = request.form.get('username'), request.form.get('password')
    for i in config.auth:
        if i == auth:
            user = i
    if user is not None:
        logger.success(f"Admin logged in from {request.remote_addr}")
        response = make_response(redirect(url_for('admin_dashboard')))
        response.set_cookie('woraw', user.woraw, max_age=timedelta(hours=1))
        response.set_cookie('wsolt', user.wsolt, max_age=timedelta(hours=1))
        _cache['login'].append((user.woraw, user.wsolt))
        return response
    else:
        logger.warning(f"Invalid login or password from {request.remote_addr}")
        flash("Invalid login or password", "error")
        return redirect(url_for('admin_index'))

@app.route('/admin', methods=['GET'])
def admin_index():
    if _check_cookie(False):
        return redirect(url_for('admin_dashboard'))
    logger.info(f"Login page opened from {request.remote_addr}")
    return render_template('index.html')

@app.route('/admin/dashboard', methods=['GET'])
def admin_dashboard():
    if not _check_cookie():
        return redirect(url_for('admin_index'))
    logger.info(f"Admin dashboard opened from {request.remote_addr}")
    p = {
        "timeouts": delays,
        "hosts": host_db.all()
    }
    return render_template('dashboard.html', **p)

@app.route(f'/admin/api/<method>', methods=['POST'])
def admin_api(method):
    if not _check_cookie():
        return get_error(4, "invalid cookie"), 403
    match method:
        case "kill_all":
            logger.info(f"Kill all command received from {request.remote_addr}")
            delays.kill_request()
            return {"message": "Command added to queue"}
        case "updates":
            return {"status": delays.status(), "hosts": host_db.all(True)}

@app.errorhandler(Exception)
def handle_error(error):
    status_code, code = 500, 9
    if hasattr(error, 'code'):
        status_code = error.code
    if status_code < 500:
        code = 8
    if status_code == 500:
        logger.exception(error)
    return get_error(code, str(error), status_code), status_code

if __name__ == '__main__':
    # Запускаем фоновую задачу проверки клиентов
    try:
        host_db.start_checking()
        app.run(host='0.0.0.0', port=5000)
    except KeyboardInterrupt:
        pass
    finally:
        host_db.stop_checking()


at scale_v = (uvs.right_bottom.v - uvs.right_top.v);

    uv_matrix.data()[3 * 2 + 0] = center_u;
    uv_matrix.data()[3 * 2 + 1] = center_v;
    uv_matrix.data()[3 * 0 + 0] = scale_u;
    uv_matrix.data()[3 * 1 + 1] = scale_v;

    glsafe(::glEnable(GL_BLEND));
    glsafe(::glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA));

    const auto& p_ogl_manager = wxGetApp().get_opengl_manager();
    const auto& gl_info = p_ogl_manager->get_gl_info();
    const auto formated_gl_version = gl_info.get_formated_gl_version();
    if (formated_gl_version < 30)
    {
        glsafe(::glEnable(GL_TEXTURE_2D));
    }
    //glsafe(::glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE));

    glsafe(::glBindTexture(GL_TEXTURE_2D, (GLuint)tex_id));
    const int stage = 0;
    glsafe(::glActiveTexture(GL_TEXTURE0 + stage));
    wxGetApp().bind_shader(p_flat_texture_shader);
    p_flat_texture_shader->set_uniform("u_texture", stage);
    p_flat_texture_shader->set_uniform("view_model_matrix", view_matrix * model_matrix);
    p_flat_texture_shader->set_uniform("projection_matrix", projection_matrix);
    p_flat_texture_shader->set_uniform("u_uvTransformMatrix", uv_matrix.matrix());
    model.render_geometry();
    wxGetApp().unbind_shader();

    glsafe(::glBindTexture(GL_TEXTURE_2D, 0));

    glsafe(::glDisable(GL_BLEND));

    if (formated_gl_version < 30) {
        glsafe(::glDisable(GL_TEXTURE_2D));
    }
}

void GLTexture::shutdown()
{
    auto& model = get_model_for_render_image();
    model.reset();
}

bool GLTexture::load_from_png(const std::string& filename, bool use_mipmaps, ECompressionType compression_type, bool apply_anisotropy)
{
    bool compression_enabled = (compression_type != None) && GLEW_EXT_texture_compression_s3tc;

    // Load a PNG with an alpha channel.
    wxImage image;
    if (!image.LoadFile(wxString::FromUTF8(filename.c_str()), wxBITMAP_TYPE_PNG)) {
        reset();
        return false;
    }

    m_width = image.GetWidth();
    m_height = image.GetHeight();

    bool requires_rescale = false;

    if (compression_enabled && compression_type == MultiThreaded) {
        // the stb_dxt compression library seems to like only texture sizes which are a multiple of 4
        int width_rem = m_width % 4;
        int height_rem = m_height % 4;

        if (width_rem != 0) {
            m_width += (4 - width_rem);
            requires_rescale = true;
        }

        if (height_rem != 0) {
            m_height += (4 - height_rem);
            requires_rescale = true;
        }
    }

    if (requires_rescale)
        image = image.ResampleBicubic(m_width, m_height);

    int n_pixels = m_width * m_height;
    if (n_pixels <= 0) {
        reset();
        return false;
    }


 fill="#9BD5F9" p-id="20151"></path><path d="M540.672 278.186667h-64.853333v249.173333h351.232v-249.173333h-286.378667z m262.826667 225.621333h-304.469334V301.397333h304.469334v202.410667zM452.608 737.621333V1024H846.506667v-286.378667H452.608z m358.4 246.784h-322.56v-207.530666h322.56v207.530666z" fill="#0086FF" p-id="20152"></path><path d="M988.16 480.597333H901.12v186.368H401.408v-186.368H313.685333c-19.797333 0-35.84 17.749333-35.84 39.594667v304.810667c0 21.845333 16.042667 39.594667 35.84 39.594666h174.421334v-87.722666h322.56v87.722666h177.493333c19.797333 0 35.84-17.749333 35.84-39.594666v-304.810667c0-21.845333-16.042667-39.594667-35.84-39.594667z m-16.725333 324.949334h-53.589334v-59.392h53.589334v59.392z" fill="#0086FF" p-id="20153"></path><path d="M545.109333 836.266667h210.944v28.330666h-210.944zM545.109333 895.658667h210.944v28.330666h-210.944z" fill="#9BD5F9" p-id="20154"></path><path d="M698.8 470.5c-126.1 0-228.2 102.2-228.2 228.2S572.7 927 698.8 927 927 824.8 927 698.8 824.8 470.5 698.8 470.5z m0 415c-103.1 0-186.8-83.6-186.8-186.8S595.6 512 698.8 512s186.8 83.6 186.8 186.8-83.7 186.7-186.8 186.7z" fill="#EE2223" p-id="33675"></path><path d="M625.4 596c-8.1-8.1-21.2-8.1-29.3 0-8.1 8.1-8.1 21.2 0 29.3l176.1 176.1c8.1 8.1 21.2 8.1 29.3 0 8.1-8.1 8.1-21.2 0-29.3L625.4 596z" fill="#EE2223" p-id="33676"></path></svg > ',
    "PrintCurrentPage":
        '<svg t="1751417454212" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="31120" width="20" height="20"><path d="M864 352V154.7c0-17.1-6.8-33.4-18.9-45.4l-91.4-90.7C741.7 6.7 725.5 0 708.6 0H160v352H96c-53 0-96 43-96 96v384h160v128c0 35.3 28.7 64 64 64h576c35.3 0 64-28.7 64-64V832h160V352H864zM224 64h478c4.2 0 8.3 1.7 11.3 4.6l82 81.3c3 3 4.7 7.1 4.7 11.4V528H224V64z m544 896H256c-17.7 0-32-14.3-32-32V720h576v208c0 17.7-14.3 32-32 32z m192-192h-96V656H160v112H64V448c0-17.7 14.3-32 32-32h64v176h704V416h96v352


::os::unix::fs::symlink(&self.shell_gc_root(), &nix_gc_root_user_dir_root.as_path())
            .map_err(|e| {
                AddRootError::symlink(
                    e,
                    self.shell_gc_root().as_path(),
                    &nix_gc_root_user_dir_root.as_path(),
                )
            })?;

        // TODO: don’t return the RootPath here
        Ok(OutputPath {
            shell_gc_root: RootPath(self.shell_gc_root()),
        })
    }
}

/// A path to a gc root.
#[derive(Hash, PartialEq, Eq, Clone, Debug, Serialize, Deserialize)]
pub struct RootPath(pub AbsPathBuf);

impl RootPath {
    /// `display` the path.
    pub fn display(&self) -> std::path::Display {
        self.0.display()
    }
}

impl OutputPath<RootPath> {
    /// Check whether all all GC roots exist.
    pub fn all_exist(&self) -> bool {
        let crate::builder::OutputPath { shell_gc_root } = self;

        shell_gc_root.0.as_path().exists()
    }
}

/// Username of the logged in (OS) user.
#[derive(Clone)]
pub struct Username(OsString);

impl Username {
    /// Read the username from the `USER` env var.
    pub fn from_env_var() -> anyhow::Result<Username> {
        std::env::var_os("USER")
            .ok_or_else(|| anyhow::anyhow!("Environment variable 'USER' must be set"))
            .map(Username)
    }
}

/// Error conditions encountered when adding roots
#[derive(Error, Debug)]
#[error("{msg}: {source}")]
pub struct AddRootError {
    #[source]
    source: std::io::Error,
    msg: String,
}

impl AddRootError {
    /// Ignore NotFound errors (it is after all a remove), and otherwise
    /// return an error explaining a delete on path failed.
    fn remove(source: std::io::Error, path: &Path) -> Result<(), AddRootError> {
        if source.kind() == std::io::ErrorKind::NotFound {
            Ok(())
        } else {
            Err(AddRootError {
                source,
                msg: format!("Failed to delete {}", path.display()),
            })
        }
    }

    /// Return an error explaining what symlink failed
    fn symlink(source: std::io::Error, src: &Path, dest: &Path) -> AddRootError {
        AddRootError {
            source,
            msg: format!("Failed to symlink {} to {}", src.display(), dest.display()),
        }
    }
}
<reponame>FlorianRohm/aoc2021<gh_stars>0
fn depth_increases(lines: &[i32]) -> usize {
    lines
        .windows(2)
        .filter(|&window| window[1] > window[0])
        .count()
}

fn depth_increases_triple(lines: &[i32]) -> usize {
    lines
        .windows(3)
        .map(|window| window.iter().sum())
        .collect::<Vec<i32>>()
        .windows(2)
        .filter(|&window| window[1] > window[0])
        .count()
}

fn solve_pt_1() -> usize {
    let input = include_str!("./input");
    let lines: Vec<i32> = input
        .trim()
        .lines()
        .map(|line| line.parse::<i32>().expect("input should be ints"))
        .collect();

    depth_increases(&lines)
}
fn solve_pt_2() -> usize {
    let input = include_str!("./input");
    let lines: Vec<


netdna.bootstrapcdn.com/bootswatch/3.0.0/cosmo/bootstrap.min.css" }, { name: "cyborg", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/cyborg/bootstrap.min.css" }, { name: "flatly", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/flatly/bootstrap.min.css" }, { name: "journal", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/journal/bootstrap.min.css" }, { name: "readable", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/readable/bootstrap.min.css" }, { name: "simplex", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/simplex/bootstrap.min.css" }, { name: "slate", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/slate/bootstrap.min.css" }, { name: "spacelab", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/spacelab/bootstrap.min.css" }, { name: "united", url: "netdna.bootstrapcdn.com/bootswatch/3.0.0/united/bootstrap.min.css" }, { name: "yeti", url: "netdna.bootstrapcdn.com/bootswatch/3.0.2/yeti/bootstrap.min.css" }], c = !1, d = { name: "Themes", version: a.md.version, once: function () { a.md.linkGimmick(this, "themechooser", h, "skel_ready"), a.md.linkGimmick(this, "theme", g) } }; a.md.registerGimmick(d); var e = a.md.getLogger(), f = function (c) { if (c.inverse = c.inverse || !1, void 0 === c.url) { if (!c.name) return void e.error("Theme name must be given!"); var d = b.filter(function (a) { return a.name === c.name })[0]; if (!d) return void e.error("Theme " + name + " not found, removing link"); c = a.extend(c, d) } a('link[rel=stylesheet][href*="netdna.bootstrapcdn.com"]').remove(); var f = a("style[id*=bootstrap]").length > 0; "bootstrap" === c.name && f || (a("style[id*=bootstrap]").remove(), a('<link rel="stylesheet" type="text/css">').attr("href", a.md.prepareLink(c.url)).appendTo("head")), c.inverse === !0 ? (a("#md-main-navbar").removeClass("navbar-default"), a("#md-main-navbar").addClass("navbar-inverse")) : (a("#md-main-navbar").addClass("navbar-default"), a("#md-main-navbar").removeClass("navbar-inverse")) }, g = function (b, d, e) { d.name = d.name || e, b.each(function (b, e) { a.md.stage("postgimmick").subscribe(function (b) { a(e); void 0 !== window.localStorage.theme && c || f(d), b() }) }), b.remove() }, h = function (d, e, f) { return c = !0, a.md.stage("bootstrap").subscribe(function (a) { i(e), a() }), d.each(function (c, d) { var e = a(d), g = a('

'); g.eq(0).text(f), a.each(b, function (b, c) { var d = a("

"); g.eq(1).append(d); a("").text(c.name).attr("href", "").click(function (a) { a.preventDefault(), window.localStorage.theme = c.name, window.location.reload() }).appendTo(d) }), g.eq(1).append('<li class="divide


depends_on.as_ref().unwrap();
		return depends_on.clone();
	}
}

///
/// Configuration structure
///
#[derive(serde_derive::Deserialize, Debug, std::clone::Clone)]
pub struct ConfigurationSettings {
	/// Environment variables
	pub env: Option<std::collections::btree_map::BTreeMap<String, String>>,

	/// Simple variables
	pub variables: Option<std::collections::btree_map::BTreeMap<String, String>>,

	/// Tasks definition
	pub tasks: Vec<Task>,
}

impl ConfigurationSettings {
	/// Returns a new instance of ConfigurationSettings
	///
	/// ### Arguments
	/// * `rmakefile_path` Path to rmake file
	///
	/// ### Returns
	/// A new instance of `ConfigurationSettings`
	pub fn new(rmakefile_path: &str) -> std::result::Result<ConfigurationSettings, Box<dyn std::error::Error>> {
		extern crate toml;

		// rmake configuration file
		let rmakefile_path = functions::select(rmakefile_path, "rmake.toml");

		// Read the whole content of given file
		println!("{} rmake [INFO] Reading rmake file ... [{}]", functions::get_timestamp(), &rmakefile_path);

		let mut content = functions::read_text_file_all(&rmakefile_path)?;

		// Read TOML file
		let conf: ConfigurationSettings = toml::from_str(&content)?;

		// Fill placeholders with variables
		if conf.variables.is_some() {
			let variables = conf.variables.as_ref().unwrap();
			for (k, v) in variables {
				println!("{} rmake [INFO] VAR [{}]=[{}]", functions::get_timestamp(), k, v);
				let place_holder = format!("{{{{{}}}}}", k);
				content = content.replace(&place_holder, &v);
			}
			if variables.len() == 0 {
				println!("{} rmake [INFO] No var defined.", functions::get_timestamp());
			}
		} else {
			println!("{} rmake [INFO] No var defined.", functions::get_timestamp());
		}

		// Re-configure by the content.
		let conf: ConfigurationSettings = toml::from_str(&content)?;

		// Retrieves and set the environment variables from configuration file
		if conf.env.is_some() {
			let env = conf.env.as_ref().unwrap();
			for (k, v) in env {
				println!("{} rmake [INFO] ENV [{}]=[{}]", functions::get_timestamp(), k, v);
				std::env::set_var(k, v);
			}
			if env.len() == 0 {
				println!("{} rmake [INFO] No env defined.", functions::get_timestamp());
			}
		} else {
			println!("{} rmake [INFO] No env defined.", functions::get_timestamp());
		}

		return Ok(conf);
	}
}
<gh_stars>1-10
use crate::geometry::*;
use crate::materials::MaterialId;
use crate::math::{
    random, random_in_unit_disk, Point3, Ray, Sampler, TangentFrame, Transform3, Vec3,
};
#[derive(Debug, Clone)]
pub struct ProjectiveCamera {
    pub origin: Point3,
    pub direction: Vec3,
    // half_height: f32,
    // half_width: f32,
    focal_distance: f32,
    lower_left_corner: Point3,
    vfov: f32,
    pub lens: Instance,
    pub horizontal: Vec3,
    pub vertical: Vec3,
    u: Vec3,
    v: Vec3,
    w: Vec3,
    lens_radius: f32,
    t0: f32,
    t1: f32,
}

impl ProjectiveCamera {
    pub fn new(
        look_from: Point3,
        look_at: Point3,
        v_up: Vec3,
        vertical_fov: f32, // vertical_fov should be given in d


.include "asm/macros.inc"
	.include "global.inc"
	.section .text
	.balign 4, 0

	thumb_func_start ov11_0225D3EC
ov11_0225D3EC: ; 0x0225D3EC
	push {r4, r5, r6, lr}
	sub sp, #0x18
	add r5, r0, #0
	mov r0, #0x1b
	str r0, [sp]
	mov r0, #0x2c
	str r0, [sp, #4]
	mov r0, #0
	str r0, [sp, #8]
	mov r0, #1
	str r0, [sp, #0xc]
	mov r0, #2
	str r0, [sp, #0x10]
	ldr r0, [sp, #0x28]
	add r4, r1, #0
	add r6, r3, #0
	str r0, [sp, #0x14]
	add r0, r2, #0
	mov r1, #3
	add r2, r5, #0
	add r3, r4, #0
	bl sub_0200C0DC
	mov r0, #1
	str r0, [sp]
	mov r0, #2
	str r0, [sp, #4]
	add r0, r5, #0
	add r1, r4, #0
	mov r2, #0x1b
	mov r3, #0xba
	str r6, [sp, #8]
	bl sub_0200C00C
	mov r0, #1
	str r0, [sp]
	ldr r0, [sp, #0x2c]
	add r1, r4, #0
	str r0, [sp, #4]
	add r0, r5, #0
	mov r2, #0x1b
	mov r3, #0xbb
	bl sub_0200C124
	mov r0, #1
	str r0, [sp]
	ldr r0, [sp, #0x30]
	add r1, r4, #0
	str r0, [sp, #4]
	add r0, r5, #0
	mov r2, #0x1b
	mov r3, #0xbc
	bl sub_0200C13C
	add sp, #0x18
	pop {r4, r5, r6, pc}

	thumb_func_start ov11_0225D45C
ov11_0225D45C: ; 0x0225D45C
	push {r4, r5, r6, lr}
	add r5, r0, #0
	add r4, r2, #0
	add r6, r3, #0
	bl sub_0200C358
	add r0, r5, #0
	add r1, r4, #0
	bl sub_0200C368
	add r0, r5, #0
	add r1, r6, #0
	bl sub_0200C378
	ldr r1, [sp, #0x10]
	add r0, r5, #0
	bl sub_0200C388
	pop {r4, r5, r6, pc}
	.align 2, 0

	thumb_func_start ov11_0225D484
ov11_0225D484: ; 0x0225D484
	push {r3, r4, r5, r6, r7, lr}
	sub sp, #0x38
	add r5, r3, #0
	mov ip, r2
	ldr r3, _0225D4FC ; =ov11_0225FEB0
	add r6, r0, #0
	add r7, r1, #0
	add r2, sp, #4
	mov r4, #6
_0225D496:
	ldmia r3!, {r


using System;
using Avalonia;
using Avalonia.Controls;

namespace Nlnet.Avalonia.Senior.Controls
{
    public class NtScrollViewer : ScrollViewer
    {
        protected override Type StyleKeyOverride { get; } = typeof(NtScrollViewer);

        public bool UseSmoothScrolling
        {
            get { return GetValue(UseSmoothScrollingProperty); }
            set { SetValue(UseSmoothScrollingProperty, value); }
        }
        public static readonly StyledProperty<bool> UseSmoothScrollingProperty = AvaloniaProperty
            .Register<NtScrollViewer, bool>(nameof(UseSmoothScrolling), true);

        public double SmoothScrollingStep
        {
            get { return GetValue


tree/master/official/vision#resnet-rs-models-trained-with-various-settings),
    \([checkpoint](https://storage.cloud.google.com/tf_model_garden/vision/resnet-rs/resnet-rs-101-i192.tar.gz)\)

2.  Config files used in our Resnet-101 ablations are included in the
    [configs folder](https://github.com/tensorflow/models/tree/master/official/projects/backbone_reuse/configs/experiments/faster_rcnn).
    Select one according to the target architecture (FPN, NASFPN, NASFPN +
    Cascades) and training schedule preference (shorter--72 epochs, or longer
    --600 epochs).

3.  Change the config flag `init_checkpoint` to point to the downloaded file.

You are all set. Follow the standard TFVision Mask-Rcnn training pipeline to
complete the training.

#### How does it work?

The config files set the task's flag `freeze_backbone: true`. This flag prevents
the pretrained backbone weights from being updated during the downstream model
training.

## Citation

```
@inproceedings{vasconcelos2022backbonefreeze,
      title = {Proper Reuse of Image Classification Features Improves Object Detection},
      author = {Cristina Vasconcelos and Vighnesh Birodkar and Vincent Dumoulin},
      booktitle={CVPR}
      year={2022},
```
# MobileBERT (MobileBERT: A Compact Task-Agnostic BERT for Resource-Limited Devices)

[MobileBERT](https://arxiv.org/abs/2004.02984)
is a thin version of BERT_LARGE, while equipped with bottleneck
structures and a carefully designed balance between self-attentions and
feed-forward networks.

To train MobileBERT, we first train a specially designed teacher model, an
inverted-bottleneck incorporated BERT_LARGE model. Then, we conduct knowledge
transfer from this teacher to MobileBERT. Empirical studies show that MobileBERT
is 4.3x smaller and 5.5x faster than BERT_BASE while achieving competitive
results on well-known benchmarks. This repository contains TensorFlow 2.x
implementation for MobileBERT.

## Network Implementations

Following
[MobileBERT TF1 implementation](https://github.com/google-research/google-research/tree/master/mobilebert),
we re-implemented MobileBERT encoder and layers using `tf.keras` APIs in NLP
modeling library:

  * [mobile_bert_encoder.py](https://github.com/tensorflow/models/blob/master/official/nlp/modeling/networks/mobile_bert_encoder.py)
  contains `MobileBERTEncoder` implementation.
  * [mobile_bert_layers.py](https://github.com/tensorflow/models/blob/master/official/nlp/modeling/layers/mobile_bert_layers.py)
  contains `MobileBertEmbedding`, `MobileBertTransformer` and `MobileBertMaskedLM`
  implementation.

## Pre-trained Models

We converted the originial TF 1.x pretrained English MobileBERT checkpoint to
TF 2.x checkpoint, which is compatible with the above implementations.
In addition, we also provide new multiple-lingual MobileBERT checkpoint
trained using multi-lingual Wiki data. Furthermore, we export the checkpoints to
TF-HUB SavedModel. Please find the details in the following table:

Model                          | Configuration                            | Number of Parameters | Training Data | Checkpoint & Vocabulary                                                                                | TF-Hub SavedModel


 left(left), right(right) {}
 * };
 */
class Solution {
public:
    bool checkEquivalence(Node* root1, Node* root2) {
        int cnt[26]{};
        function<void(Node*, int)> dfs = [&](Node* root, int v) {
            if (!root) {
                return;
            }
            if (root->val != '+') {
                cnt[root->val - 'a'] += v;
            }
            dfs(root->left, v);
            dfs(root->right, v);
        };
        dfs(root1, 1);
        dfs(root2, -1);
        for (int& x : cnt) {
            if (x) {
                return false;
            }
        }
        return true;
    }
};
```

#### JavaScript

```js
/**
 * Definition for a binary tree node.
 * function Node(val, left, right) {
 *     this.val = (val===undefined ? " " : val)
 *     this.left = (left===undefined ? null : left)
 *     this.right = (right===undefined ? null : right)
 * }
 */
/**
 * @param {Node} root1
 * @param {Node} root2
 * @return {boolean}
 */
var checkEquivalence = function (root1, root2) {
    const cnt = new Array(26).fill(0);
    const dfs = (root, v) => {
        if (!root) {
            return;
        }
        if (root.val !== '+') {
            cnt[root.val.charCodeAt(0) - 'a'.charCodeAt(0)] += v;
        }
        dfs(root.left, v);
        dfs(root.right, v);
    };
    dfs(root1, 1);
    dfs(root2, -1);
    for (const x of cnt) {
        if (x) {
            return false;
        }
    }
    return true;
};
```

<!-- tabs:end -->

<!-- solution:end -->

<!-- solution:start -->

### Solution 2

<!-- tabs:start -->

#### Python3

```python
# Definition for a binary tree node.
# class Node(object):
#     def __init__(self, val=" ", left=None, right=None):
#         self.val = val
#         self.left = left
#         self.right = right
class Solution:
    def checkEquivalence(self, root1: 'Node', root2: 'Node') -> bool:
        def dfs(root):
            cnt = [0] * 26
            if root is None:
                return cnt
            if root.val in '+-':
                l, r = dfs(root.left), dfs(root.right)
                k = 1 if root.val == '+' else -1
                for i in range(26):
                    cnt[i] += l[i] + r[i] * k
            else:
                cnt[ord(root.val) - ord('a')] += 1
            return cnt

        return dfs(root1) == dfs(root2)
```

#### Java

```java
/**
 * Definition for a binary tree node.
 * class Node {
 *     char val;
 *     Node left;
 *     Node right;
 *     Node() {this.val = ' ';}
 *     Node(char val) { this.val = val; }
 *     Node(char val, Node left, Node right) {
 *         this.val = val;
 *         this.left = left;
 *         this.right = right;
 *     }
 * }
 */
class Solution {
    public boolean checkEquivalence(Node root1, Node root2) {
        int[] cnt1 = dfs(root1);
        int[] cnt2 = dfs(root2);
        for (int i = 0; i < 26; ++i) {
            if (cnt1[i] != cnt2[i]) {
                return false;
            }
        }


ignInBits,
      OffsetInBits, Flags, nullptr, RuntimeLang, nullptr, nullptr, Identifier,
      Discriminator);
  auto *Other = DICompositeType::get(
      Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, AlignInBits,
      OffsetInBits, Flags, nullptr, RuntimeLang, nullptr, nullptr, Identifier,
      Discriminator2);
  auto *NoDisc = DICompositeType::get(
      Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, AlignInBits,
      OffsetInBits, Flags, nullptr, RuntimeLang, nullptr, nullptr, Identifier,
      nullptr);

  EXPECT_EQ(N, Same);
  EXPECT_NE(Same, Other);
  EXPECT_NE(Same, NoDisc);
  EXPECT_NE(Other, NoDisc);

  EXPECT_EQ(N->getDiscriminator(), Discriminator);
}

typedef MetadataTest DISubroutineTypeTest;

TEST_F(DISubroutineTypeTest, get) {
  DINode::DIFlags Flags = static_cast<DINode::DIFlags>(1);
  DINode::DIFlags FlagsPOne = static_cast<DINode::DIFlags>(Flags + 1);
  MDTuple *TypeArray = getTuple();

  auto *N = DISubroutineType::get(Context, Flags, 0, TypeArray);
  EXPECT_EQ(dwarf::DW_TAG_subroutine_type, N->getTag());
  EXPECT_EQ(Flags, N->getFlags());
  EXPECT_EQ(TypeArray, N->getTypeArray().get());
  EXPECT_EQ(N, DISubroutineType::get(Context, Flags, 0, TypeArray));

  EXPECT_NE(N, DISubroutineType::get(Context, FlagsPOne, 0, TypeArray));
  EXPECT_NE(N, DISubroutineType::get(Context, Flags, 0, getTuple()));

  // Test the hashing of calling conventions.
  auto *Fast = DISubroutineType::get(
      Context, Flags, dwarf::DW_CC_BORLAND_msfastcall, TypeArray);
  auto *Std = DISubroutineType::get(Context, Flags,
                                    dwarf::DW_CC_BORLAND_stdcall, TypeArray);
  EXPECT_EQ(Fast,
            DISubroutineType::get(Context, Flags,
                                  dwarf::DW_CC_BORLAND_msfastcall, TypeArray));
  EXPECT_EQ(Std, DISubroutineType::get(
                     Context, Flags, dwarf::DW_CC_BORLAND_stdcall, TypeArray));

  EXPECT_NE(N, Fast);
  EXPECT_NE(N, Std);
  EXPECT_NE(Fast, Std);

  TempDISubroutineType Temp = N->clone();
  EXPECT_EQ(N, MDNode::replaceWithUniqued(std::move(Temp)));

  // Test always-empty operands.
  EXPECT_EQ(nullptr, N->getScope());
  EXPECT_EQ(nullptr, N->getFile());
  EXPECT_EQ("", N->getName());
}

typedef MetadataTest DIFileTest;

TEST_F(DIFileTest, get) {
  StringRef Filename = "file";
  StringRef Directory = "dir";
  DIFile::ChecksumKind CSKind = DIFile::ChecksumKind::CSK_MD5;
  StringRef ChecksumString = "000102030405060708090a0b0c0d0e0f";
  DIFile::ChecksumInfo<StringRef> Checksum(CSKind, ChecksumString);
  StringRef Source = "source";
  auto *N = DIFile::get(Context, Filename, Directory, Checksum, Source);

  EXPECT_EQ(dwarf::DW_TAG_file_type, N->getTag());
  EXPECT_EQ(Filename, N->getFilename());
  EXPECT_EQ(Directory, N->getDirectory());
  EXPECT_EQ(Checksum, N->getChecksum());


erator<Item = (usize, f64)>> {
    signal: I,
    lag: usize,
    threshold: f64,
    influence: f64,
}

pub(crate) trait FftPeaks<I>
where
    I: Iterator<Item = (usize, f64)>,
{
    fn fft_peaks(self, lag: usize, threshold: f64, influence: f64) -> PeakIter<I>;
}

impl<I> FftPeaks<I> for I
where
    I: Iterator<Item = (usize, f64)>,
{
    fn fft_peaks(self, lag: usize, threshold: f64, influence: f64) -> PeakIter<I> {
        PeakIter {
            signal: self,
            lag,
            threshold,
            influence,
        }
    }
}

impl<I> Iterator for PeakIter<I>
where
    I: Iterator<Item = (usize, f64)>,
{
    type Item = FftBin;

    fn next(&mut self) -> Option<Self::Item> {
        let fft_bins: Vec<FftBin> = self
            .signal
            .by_ref()
            .peaks(PeaksDetector::new(self.lag, self.threshold, 0.0), |e| e.1)
            .skip_while(|(_, peak)| *peak == Peak::None)
            .take_while(|(_, peak)| *peak == Peak::High)
            .map(|(bin, _)| FftBin {
                bin: bin.0,
                magnitude: bin.1,
            })
            .collect();
        fft_bins
            .iter()
            .reduce(|accum, item| {
                if item.magnitude > accum.magnitude {
                    item
                } else {
                    accum
                }
            })
            .map(|fft_bin| fft_bin.clone())
    }
}
<filename>src/lit.rs
use std::fmt;
use std::hash::{Hash, Hasher};

use proc_macro2::{self, Literal, TokenNode, Term};

use {Span, TokenTree};

#[derive(Clone)]
pub struct Lit {
    pub value: LitKind,
    pub span: Span,
}

#[derive(Clone)]
pub enum LitKind {
    Bool(bool),
    Other(Literal),
}

impl Lit {
    pub fn into_token_tree(self) -> TokenTree {
        let kind = match self.value {
            LitKind::Bool(true) => TokenNode::Term(Term::intern("true")),
            LitKind::Bool(false) => TokenNode::Term(Term::intern("false")),
            LitKind::Other(l) => TokenNode::Literal(l),
        };
        TokenTree(proc_macro2::TokenTree {
            span: self.span.0,
            kind: kind,
        })
    }
}

impl fmt::Display for Lit {
    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        fmt::Display::fmt(&self.value, f)
    }
}

impl fmt::Debug for Lit {
    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        fmt::Display::fmt(&self.value, f)
    }
}

impl PartialEq for Lit {
    fn eq(&self, other: &Lit) -> bool {
        self.value == other.value
    }
}

impl Eq for Lit {}

impl Hash for Lit {
    fn hash<H: Hasher>(&self, hasher: &mut H) {
        self.value.hash(hasher)
    }
}

impl fmt::Display for LitKind {
    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        match *self {
            LitKind::Bool(b) => b.fmt(f),
            LitKind::Other(ref l) => l.fmt(f),
        }
    }
}

impl fmt::Debug for LitKind {
    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        match *self {
            LitKind::Bool(b) => b.fmt(f),
            LitKind::Other(


 2, ANIM_DEF_PARTNER, 3, 0, 12, 1
	delay 4
	createsprite gRandomPosHitSplatSpriteTemplate, ANIM_TARGET, 3, 1, 3
	playsewithpan SE_M_COMET_PUNCH, SOUND_PAN_TARGET
	delay 4
	createsprite gRandomPosHitSplatSpriteTemplate, ANIM_TARGET, 3, 1, 3
	playsewithpan SE_M_COMET_PUNCH, SOUND_PAN_TARGET
	delay 4
	createsprite gBasicHitSplatSpriteTemplate, ANIM_TARGET, 3, 32, 20, ANIM_TARGET, 3
	playsewithpan SE_M_COMET_PUNCH, SOUND_PAN_TARGET
	waitforvisualfinish
	clearmonbg ANIM_DEF_PARTNER
	blendoff
	end

Move_MAGICAL_LEAF:
	loadspritegfx ANIM_TAG_LEAF
	loadspritegfx ANIM_TAG_RAZOR_LEAF
	loadspritegfx ANIM_TAG_IMPACT
	monbg ANIM_DEF_PARTNER
	setalpha 12, 8
	delay 1
	loopsewithpan SE_M_POISON_POWDER, SOUND_PAN_ATTACKER, 10, 5
	createvisualtask AnimTask_CycleMagicalLeafPal, 5
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, -3, -2, 10
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, -1, -1, 15
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, -4, -4, 7
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, 3, -3, 11
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, -1, -6, 8
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, 2, -1, 12
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, -3, -4, 13
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, 4, -5, 7
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, 2, -6, 11
	delay 2
	createsprite gRazorLeafParticleSpriteTemplate, ANIM_ATTACKER, 2, -3, -5, 8
	delay 60
	playsewithpan SE_M_RAZOR_WIND2, SOUND_PAN_ATTACKER
	createsprite gRazorLeafCutterSpriteTemplate, ANIM_TARGET, 3, 20, -10, 20, 0, 32, 20, 0
	createsprite gRazorLeafCutterSpriteTemplate, ANIM_TARGET, 3, 20, -10, 20, 0, 32, -20, 0
	delay 30
	playsewithpan SE_M_RAZOR_WIND, SOUND_PAN_TARGET
	createsprite gBasicHitSplatSpriteTemplate, ANIM_TARGET, 4, -10, -4, ANIM_TARGET, 2
	createsprite gBasicHitSplatSpriteTemplate, ANIM_TARGET, 4, 10, 4, ANIM_TARGET, 2
	createvisualtask AnimTask_ShakeMon2, 2, ANIM_TARGET, 2, 0, 8, 1
	delay 20
	setarg 7, 0xFFFF
	waitforvisualfinish
	clearmonbg ANIM_DEF_PARTNER
	blendoff
	end

Move_ICE_BALL:
	loadspritegfx ANIM_TAG_ICE_CHUNK
	loadspritegfx ANIM_TAG


                                                                              \
        if (parts < 3)                                                        \
          version <<= 8 * (3 - parts);                                        \
                                                                              \
        /* Now we can test with the required version.  */                     \
        if (version < __LINUX_KERNEL_VERSION)                                 \
          /* Not sufficient.  */                                               \
          FATAL ("FATAL: kernel too old\n");                                  \
                                                                              \
        _dl_osversion = version;                                              \
      }                                                                       \
  } while (0)

int main(void)
{
        char bufmem[64] = "2.6.22";
        char *buf = bufmem;
        unsigned int version;
        int parts;
        char *cp;

        version = 0;
        parts = 0;
        cp = buf;
        while ((*cp >= '0') && (*cp <= '9'))
          {
            unsigned int here = *cp++ - '0';

            while ((*cp >= '0') && (*cp <= '9'))
              {
                here *= 10;
                here += *cp++ - '0';
              }

            ++parts;
            version <<= 8;
            version |= here;

            if (*cp++ != '.')
              /* Another part following?  */
              break;
          }

        if (parts < 3)
          version <<= 8 * (3 - parts);
        if (version < __LINUX_KERNEL_VERSION)
                err();
        pass();
        exit(0);
}


://nextjs.org/docs/api-routes/introduction
import type { NextApiRequest, NextApiResponse } from "next";

type Data = {
  items: Array<any>;
};

const posts = [
  { id: 1, title: "Next JS", body: "Very good" },
  { id: 2, title: "React JS", body: "Best" },
  { id: 3, title: "Vue JS", body: "Very nice" },
];

export default function handler(
  req: NextApiRequest,
  res: NextApiResponse<Data>
) {
  res.status(200).json({ items: posts });
}
import {readInitialState, readNotes, Pots, Pot} from "./Day12";
import {expect} from "chai";

describe('Subterranean Sustainability', () => {

    let initialState : string = '#..#.#..##......###...###';

    let notes : string =
        '...## => #\n' +
        '..#.. => #\n' +
        '.#... => #\n' +
        '.#.#. => #\n' +
        '.#.## => #\n' +
        '.##.. => #\n' +
        '.#### => #\n' +
        '#.#.# => #\n' +
        '#.### => #\n' +
        '##.#. => #\n' +
        '##.## => #\n' +
        '###.. => #\n' +
        '###.# => #\n' +
        '####. => #';

    it ('should determine all the states for 20 generations', () => {
        let expectedGenStates : string[] = [
           '...#...#....#.....#..#..#..#...',
           '...##..##...##....#..#..#..##..',
           '..#.#...#..#.#....#..#..#...#...',
           '....#.#..#...#.#...#..#..##..##..',
           '.....#...##...#.#..#..#...#...#...',
           '.....##.#.#....#...#..##..##..##..',
           '....#..###.#...##..#...#...#...#...',
           '....#....##.#.#.#..##..##..##..##..',
           '....##..#..#####....#...#...#...#...',
           '...#.#..#...#.##....##..##..##..##..',
           '....#...##...#.#...#.#...#...#...#...',
           '....##.#.#....#.#...#.#..##..##..##..',
           '...#..###.#....#.#...#....#...#...#...',
           '...#....##.#....#.#..##...##..##..##..',
           '...##..#..#.#....#....#..#.#...#...#...',
           '..#.#..#...#.#...##...#...#.#..##..##..',
           '....#...##...#.#.#.#...##...#....#...#...',
           '....##.#.#....#####.#.#.#...##...##..##..',
           '...#..###.#..#.#.#######.#.#.#..#.#...#...',
           '...#....##....#####...#######....#.#..##..'
        ];

        let parsedInitialState = readInitialState(initialState);
        let parsedNotes = readNotes(notes);
        let pots : Pots = new Pots(parsedInitialState, parsedNotes);

        for (let i = 1; i <= 20; i++) {
            pots.applyNotesToPots();
            let twentyGenState : string = pots.generateOutputStateString();
            expect(twentyGenState).to.equal(expectedGenStates[i-1]);
        }
    });

    it ('should determine the correct potNumberSum after 20 generations', () => {
        let parsedInitialState = readInitialState(initialState);
        let parsedNotes = readNotes(notes);
        let pots : Pots = new Pots(parsedInitialState, parsedNotes)

        let potNumberSum : number = pots.countPotsAfterGenerations(20);

        expect(potNumberSum).to.equal(325);


#region Common Public License Copyright Notice
/**************************************************************************\
* Natural Object-Role Modeling Architect for Visual Studio                 *
*                                                                          *
* Copyright © Neumont University. All rights reserved.                     *
* Copyright © ORM Solutions, LLC. All rights reserved.                     *
*                                                                          *
* The use and distribution terms for this software are covered by the      *
* Common Public License 1.0 (http://opensource.org/licenses/cpl) which     *
* can be found in the file CPL.txt at the root of this distribution.       *
* By using this software in any fashion, you are agreeing to be bound by   *
* the terms of this license.                                               *
*                                                                          *
* You must not remove this notice, or any other, from this software.       *
\**************************************************************************/
#endregion
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

using DslModeling = global::Microsoft.VisualStudio.Modeling;
using DslDesign = global::Microsoft.VisualStudio.Modeling.Design;
using DslDiagrams = global::Microsoft.VisualStudio.Modeling.Diagrams;

[module: global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Maintainability", "CA1506:AvoidExcessiveClassCoupling", Scope = "type", Target = "ORMSolutions.ORMArchitect.Views.BarkerERView.BarkerERDiagram")]

namespace ORMSolutions.ORMArchitect.Views.BarkerERView
{
	/// <summary>
	/// Double-derived base class for DomainClass BarkerERDiagram
	/// </summary>
	[global::System.ComponentModel.TypeDescriptionProvider(typeof(global::ORMSolutions.ORMArchitect.Framework.Diagrams.Design.PresentationElementTypeDescriptionProvider<BarkerERDiagram, global::ORMSolutions.ORMArchitect.EntityRelationshipModels.Barker.BarkerErModel, global::ORMSolutions.ORMArchitect.Framework.Diagrams.Design.PresentationElementTypeDescriptor<BarkerERDiagram, global::ORMSolutions.ORMArchitect.EntityRelationshipModels.Barker.BarkerErModel>>))]
	[DslDesign::DisplayNameResource("ORMSolutions.ORMArchitect.Views.BarkerERView.BarkerERDiagram.DisplayName", typeof(global::ORMSolutions.ORMArchitect.Views.BarkerERView.BarkerERShapeDomainModel), "ORMSolutions.ORMArchitect.Views.BarkerERView.GeneratedCode.DomainModelResx")]
	[DslDesign::DescriptionResource("ORMSolutions.ORMArchitect.Views.BarkerERView.BarkerERDiagram.Description", typeof(global::ORMSolutions.ORMArchitect.Views.BarkerERView.BarkerERShapeDomainModel), "ORMSolutions.ORMArchitect.Views.BarkerERView.GeneratedCode.DomainModelResx")]
	[DslModeling::DomainModelOwner(typeof(global::ORMSolutions.ORMArchitect.Views.BarkerERView.BarkerERShapeDomainModel))]
	[DslModeling::DomainObjectId("144546c5-db5e-4a4c-b1bc-4b7c6c0612f2")]
	internal abstract partial class BarkerERDiagramBase : DslDiagrams::Diagram
	{
		#region Diagram boilerplate
		private static DslDiagrams::StyleSet classStyleSet;
		private static global::System.Collections.Generic.IList<DslDiagrams::ShapeField> shapeFields;
		/// <summary>
		/// Per-class style set for this shape.
		/// </summary>
		protected override DslDiagrams::StyleSet ClassStyleSet
		{
			get
			{
				if (classStyleSet == null)
				{
					classStyleSet = CreateClassStyleSet();
				}
				return classStyleSet;
			}
		}

		/// <summary>
		/// Pe


 objects",
                coreDataNotifier.sysStats != null
                    ? coreDataNotifier.sysStats!.liveObjects .toString()
                    : "0"),
          ],
        );
      },
    );
  }

  @override
  void dispose() {
    // timer.cancel();
    super.dispose();
  }
}
import 'package:flutter/material.dart';
import 'package:fv2ray/utils/core_data_notifier.dart';

import '../../../utils/format_byte.dart';

class TrafficStats extends StatefulWidget {
  const TrafficStats({super.key});

  @override
  State<TrafficStats> createState() => _TrafficStatsState();
}

class _TrafficStatsState extends State<TrafficStats> {
  final limitCount = 60;

  @override
  void initState() {
    super.initState();
  }

  Widget keyValueRow(String key, String value) {
    return Row(
      mainAxisAlignment: MainAxisAlignment.spaceBetween,
      children: [
        Text(
          key,
        ),
        Text(
          value,
        ),
      ],
    );
  }

  @override
  Widget build(BuildContext context) {
    return ListenableBuilder(
      listenable: coreDataNotifier,
      builder: (BuildContext context, Widget? child) {
        return Column(
          mainAxisAlignment: MainAxisAlignment.start,
          crossAxisAlignment: CrossAxisAlignment.start,
          children: [
            keyValueRow(
              "direct ↑",
              formatBytes(
                  coreDataNotifier.trafficStatAgg[TrafficStatType.directUp]!),
            ),
            keyValueRow(
              "direct ↓",
              formatBytes(
                  coreDataNotifier.trafficStatAgg[TrafficStatType.directDn]!),
            ),
            keyValueRow(
              "proxy ↑",
              formatBytes(coreDataNotifier.trafficStatAgg[TrafficStatType.proxyUp]!),
            ),
            keyValueRow(
              "proxy ↓",
              formatBytes(coreDataNotifier.trafficStatAgg[TrafficStatType.proxyDn]!),
            ),
          ],
        );
      },
    );
  }

  @override
  void dispose() {
    // timer.cancel();
    super.dispose();
  }
}
import 'package:animated_tree_view/animated_tree_view.dart';
import 'package:drift/drift.dart';
import 'package:flutter/material.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
import 'package:fv2ray/models/asset.dart';
import 'package:smooth_highlight/smooth_highlight.dart';

import '../../../screens/core.dart';
import '../../../utils/db.dart';
import '../../core_type.dart';

class CoresScreen extends StatefulWidget {
  const CoresScreen({
    super.key,
  });

  @override
  State<CoresScreen> createState() => _CoresScreenState();
}

enum CoresAction {
  addCore,
  addCoreType,
}

extension ToLCString on CoresAction {
  String toShortString(context) {
    switch (this) {
      case CoresAction.addCore:
        return AppLocalizations.of(context)!.addCore;
      case CoresAction.addCoreType:
        return AppLocalizations.of(context)!.addCoreType;
    }
  }
}

enum CoreAction {
  delete,
  edit,
}

enum CoreTypeAction {
  delete,
  edit,
}

class _CoresScreenState extends State<CoresScreen> {
  var _highlightCoresPopupMenuButton = false;

  void setHighlightCoresPopupMenuButton() async {
    for (var i = 0; i < 5; ++i) {
      if (mounted) {
        setState(() {
          _highlightCoresPopupMenuButton = true;
        });
        await Future.delayed(const Duration(milliseconds: 1500));
      } else {
        return;
      }
    }
  }

  void handleCoresAction(action) {
    switch (action) {
      case CoresAction.addCore:
        _addCore();


glabel func_8096EDC0
/* 01910 8096EDC0 27BDFFE0 */  addiu   $sp, $sp, 0xFFE0           ## $sp = FFFFFFE0
/* 01914 8096EDC4 3C0E8097 */  lui     $t6, %hi(func_8096EBBC)    ## $t6 = 80970000
/* 01918 8096EDC8 3C0F8097 */  lui     $t7, %hi(func_8096ED40)    ## $t7 = 80970000
/* 0191C 8096EDCC AFBF001C */  sw      $ra, 0x001C($sp)
/* 01920 8096EDD0 25EFED40 */  addiu   $t7, $t7, %lo(func_8096ED40) ## $t7 = 8096ED40
/* 01924 8096EDD4 25CEEBBC */  addiu   $t6, $t6, %lo(func_8096EBBC) ## $t6 = 8096EBBC
/* 01928 8096EDD8 AFAE0010 */  sw      $t6, 0x0010($sp


--[[
/*
 * EJERCICIO:
 * - Muestra ejemplos de creación de todas las estructuras soportadas por defecto en tu lenguaje.
 * - Utiliza operaciones de inserción, borrado, actualización y ordenación.
 *
 * DIFICULTAD EXTRA (opcional):
 * Crea una agenda de contactos por terminal.
 * - Debes implementar funcionalidades de búsqueda, inserción, actualización y eliminación de contactos.
 * - Cada contacto debe tener un nombre y un número de teléfono.
 * - El programa solicita en primer lugar cuál es la operación que se quiere realizar, y a continuación
 *   los datos necesarios para llevarla a cabo.
 * - El programa no puede dejar introducir números de teléfono no númericos y con más de 11 dígitos.
 *   (o el número de dígitos que quieras)
 * - También se debe proponer una operación de finalización del programa.
 */
]]

local tabla = { --equivalencia a lista
    3,8,6,2,7,10,1,11
}

print("")
print("\ntabla original : " .. table.concat(tabla , ","))

-- aunque la clase table es util , solo funciona para tablas de listas no para clave y valor
-- su uso es mas recomendable para lista de numeros

table.insert(tabla , 20)
print("agregar valor a tabla : " .. table.concat(tabla , ","))

table.remove(tabla , 1)
print("eliminar valor de tabla : " .. table.concat(tabla , ","))

table.sort(tabla)
print("ordenar la tabla : ".. table.concat(tabla , ","))

tabla[1] = 5
print("actualizar valor de tabla : " .. table.concat(tabla , ",") )

local tabla2 = { -- equivalencia a Diccionarios o JSON
    Erno_rubik = "cubo3X3X3",
    Einstein = "E = MC^2",
    Euler = "e",
    Emmy_noether = "Algebra"
}

-- Para imprimir una tabla de tipo diccionario, necesitas iterar sobre sus pares clave-valor.
local function mostra_json()
    for clave, valor in pairs(tabla2) do
        print(clave .. " : " .. valor)
    end
end
print("\ntabla json original :")
mostra_json()

-- Para agregar un nuevo par clave-valor, simplemente asigna el valor a la clave
tabla2["steve_hawkings"] = "agujero negro"
print("\nDespues de agregar un nuevo par clave-valor:")
mostra_json()

-- eliminar valor de json/tabla

tabla2.Emmy_noether = nil -- nil significa nada
print("\neliminando un valor d


leal	4(%edi),%edi
	subl	$1,%ecx
	jnz	.L027loop
	movl	24(%esp),%eax
.L026nogo:
	popl	%edi
	popl	%esi
	popl	%ebx
	popl	%ebp
	ret
.size	OPENSSL_instrument_bus,.-.L_OPENSSL_instrument_bus_begin
.globl	OPENSSL_instrument_bus2
.type	OPENSSL_instrument_bus2,@function
.align	16
OPENSSL_instrument_bus2:
.L_OPENSSL_instrument_bus2_begin:
	pushl	%ebp
	pushl	%ebx
	pushl	%esi
	pushl	%edi
	movl	$0,%eax
	call	.L028PIC_me_up
.L028PIC_me_up:
	popl	%edx
	leal	OPENSSL_ia32cap_P-.L028PIC_me_up(%edx),%edx
	btl	$4,(%edx)
	jnc	.L029nogo
	btl	$19,(%edx)
	jnc	.L029nogo
	movl	20(%esp),%edi
	movl	24(%esp),%ecx
	movl	28(%esp),%ebp
	.byte	0x0f,0x31
	movl	%eax,%esi
	movl	$0,%ebx
	clflush	(%edi)
.byte	240
	addl	%ebx,(%edi)
	.byte	0x0f,0x31
	movl	%eax,%edx
	subl	%esi,%eax
	movl	%edx,%esi
	movl	%eax,%ebx
	jmp	.L030loop2
.align	16
.L030loop2:
	clflush	(%edi)
.byte	240
	addl	%eax,(%edi)
	subl	$1,%ebp
	jz	.L031done2
	.byte	0x0f,0x31
	movl	%eax,%edx
	subl	%esi,%eax
	movl	%edx,%esi
	cmpl	%ebx,%eax
	movl	%eax,%ebx
	movl	$0,%edx
	setne	%dl
	subl	%edx,%ecx
	leal	(%edi,%edx,4),%edi
	jnz	.L030loop2
.L031done2:
	movl	24(%esp),%eax
	subl	%ecx,%eax
.L029nogo:
	popl	%edi
	popl	%esi
	popl	%ebx
	popl	%ebp
	ret
.size	OPENSSL_instrument_bus2,.-.L_OPENSSL_instrument_bus2_begin
.globl	OPENSSL_ia32_rdrand_bytes
.type	OPENSSL_ia32_rdrand_bytes,@function
.align	16
OPENSSL_ia32_rdrand_bytes:
.L_OPENSSL_ia32_rdrand_bytes_begin:
	pushl	%edi
	pushl	%ebx


然后进行不同的组合，组成新的故事。

比如刚刚上面例子：小佳那个，用的是素材库 152453，也可以用 12345 来编一个，或用 22335 也行，以此类推，只需作一点点调整即可。

我再举个简单的例子：

主人公：2 小爱 26 岁，财务；其他人物是小王 29 岁，业务员，他们是夫妻

故事主干：他们想生个孩子（梦想或目标 1），可是结婚 3 年也没怀上（挫折或意外 1）他们看了许多医生，吃了很多药，也没用，他们认命了，不再治了，却在 1 年后，怀上了孩子（惊喜或反转 4）

结局：7 夫妻更恩爱了。

以上结合起来就是一个小故事雏形，如下：

我叫小爱，今年 26 岁，做财务工作；我老公叫小王，29 岁，是个业务员。

我们结婚 3 年多了，一直想要个孩子，可是没有避孕，也一直没怀上。

我们去看了许多医生，吃了很多药，也没用。

我们认命了，不再治了，却在 1 年后，意外怀上了孩子。

这样，一个小故事的雏形就出来了，但这样字数太少，也不够吸引人，需要往里面填充一些细节、情节，填充的越曲折越好。

把故事填充写完之后，就是加观点，和信息量的时候，也就是结尾了。

故事写完后， @自己一下，然后加上一些，自己的总结观点或感悟。

最后，再抛给读者一个问题，这个问题可以是问读者：认不认同你的观点，也可以是问读者：对这个故事里发生的事、有什么看法或观点，反正自己想问什么就问什么。这样，一篇完整的故事文就完成了。

比如：上面小爱那个例子，我们可以给出这样的观点：怀不上孩子的夫妻，不要放弃，只要肯积极就医，放松心情，还是会出现奇迹的。

可以抛出一个这样的问题给读者讨论：你身边有不孕不育的夫妻吗？他们后来生孩子了吗？

其实，这个总结的观点、感悟和问题，可以随便按你的意思来，但不能不写。

这个观点或感悟，如果可以引用一些心灵鸡汤，或名人名言，电影、电视、什么书的金句，那就更好了。

大家以后看电影、看新闻、看书、刷