{"problem":{"name":"『STA - R5』消失的计算机","description":{"content":"**本题为提交答案题。** 后台有一个正整数 $n$（你不知道 $n$ 具体的值）。 你有 $10^3$ 个变量 $p_1,p_2,\\cdots,p_{10^3}$，初始 $p_1=n$，$p_2=p_3=\\cdots=p_{10^3}=0$。 你需要写一个程序完成一些任务，程序包含下面几种语句可供使用： - `new x`，令 $n\\gets n+1$，$p_x\\gets n$。 - `d","description_type":"Markdown"},"platform":"Luogu","limit":{"time_limit":3000,"memory_limit":524288},"difficulty":{"LuoguStyle":"P7"},"is_remote":true,"is_sync":true,"sync_url":null,"sign":"LGP10400"},"statements":[{"statement_type":"Markdown","content":"**本题为提交答案题。**\n\n后台有一个正整数 $n$（你不知道 $n$ 具体的值）。\n\n你有 $10^3$ 个变量 $p_1,p_2,\\cdots,p_{10^3}$，初始 $p_1=n$，$p_2=p_3=\\cdots=p_{10^3}=0$。\n\n你需要写一个程序完成一些任务，程序包含下面几种语句可供使用：\n- `new x`，令 $n\\gets n+1$，$p_x\\gets n$。\n- `dec x`，令 $p_x\\gets p_x-1$。\n- `assign x y`，令 $p_x\\gets p_y$。\n- `iftry x goto l`，如果 $p_x \\ge 0$，跳转到第 $l$ 条语句。\n- `ifeq x y goto l`，如果 $p_x = p_y$，跳转到第 $l$ 条语句。\n- `ifneq x y goto l`，如果 $p_x\\neq p_y$，跳转到第 $l$ 条语句。\n\n对于后三种语句，**如果当前语句是第 $\\bm{l_0}$ 条，那么要求 $\\bm{l<l_0}$。**\n\n你不得使用超过 $1000$ 条语句或是标号超过 $1000$ 的变量。你的程序实际语句运行次数不得超过 $10^5$。\n\n令程序执行前的 $n$ 值为程序的输入，程序执行后的 $n$ 值为程序的输出，你需要分别完成下面 $10$ 个任务：\n\n1. 输入 $n$，输出 $2n$。\n1. 输入 $n$，输出 $\\binom n2$。\n1. 输入 $n$，输出 $600$。\n1. 输入 $n$，输出 $n + 1$。\n1. 输入 $n$，输出 $n^2 - 1$。\n1. 输入 $n$，输出 $n + 2000$。\n1. 输入 $n$，输出 $n + \\lfloor \\log_2 n\\rfloor$。\n1. 输入 $n$，输出 $n + \\left(n \\bmod 2\\right) + 1$。\n1. 输入 $n$，输出 $n+\\gcd(n, n - 4) + 1$。\n1. 输入 $n$，输出一个满足 $|x-n\\ln n|\\le 30$ 的正整数 $x$。\n\n**注：子任务按长度排序，与难度无关。**\n\n## Input\n\n该题为提交答案型试题，每个测试点对应的任务见【题目描述】。\n\n## Output\n\n针对给定的 $10$ 个任务，你需要分别提交你的输出文件 ``1.out`` ~ ``10.out``。\n\n每个文件需要输出若干行。\n\n第一行一个非负整数 $L$，代表你使用的语句数量。\n\n接下来 $L$ 行，每行一个语句。\n\n[samples]\n\n## Note\n\n**评分标准**\n\n对于每个测试点，其内部会评测若干组测试数据。\n\n若你的输出出现下列情况，那么该测试点不得分：\n\n- 输出与要求不符。\n- 实际语句运行次数大于 $10^5$。\n- 出现无法识别或不合法的语句。\n- 使用超过 $1000$ 条语句或是标号超过 $1000$ 的变量。\n\n否则设对应子任务的评分标准为 $L_0$，那么你的得分为：\n\n$$\\mathrm{score}=\\begin{cases}11&L_0>L\\\\\\Big\\lfloor\\frac{10}{\\exp\\left(1-\\frac {L_0}L\\right)}\\Big\\rfloor&\\text{otherwise.}\\end{cases}$$\n\n下面给出各个任务对应的评分标准 $L_0$:\n\n| 编号 | $1$ | $2$ | $3$ | $4$ | $5$| $6$ | $7$ | $8$ | $9$ | $10$ |\n| :-: | :-: | :-: | :-: | :-: | :-: |  :-: | :-: | :-: | :-: | :-: |\n| $L_0$ | $3$ | $9$ | $233$ | $1$ | $10$| $29$ | $14$ | $7$ | $18$ | $14$ |\n\n**数据范围**\n\n保证 $5 \\le n \\le 100$。","is_translate":false,"language":"English"}],"meta":{"iden":"LGP10400","tags":["提交答案","Special Judge","O2优化"],"sample_group":[],"created_at":"2026-03-03 11:09:25"}}