🎯 从整数列表中抽取Pick an Integer
从整数列表中随机抽取一个或多个(可设种子复现,可要求不重复)。适合抽签和抽样,本地处理。Pick one or more integers at random from a list (optional seed for reproducibility; optional unique picks). Handy for draws and sampling. Processed locally.
使用说明与常见问题How-to & FAQ
「从整数列表中抽取」是什么?What is the Pick an Integer tool?
从整数列表中随机抽取一个或多个(可设种子复现,可要求不重复)。适合抽签和抽样,本地处理。Pick one or more integers at random from a list (optional seed for reproducibility; optional unique picks). Handy for draws and sampling. Processed locally.
如何使用「从整数列表中抽取」?How do I use the Pick an Integer tool?
在「从整数列表中抽取」中,把内容粘贴或输入到上方输入框,按需设置「抽取个数」、「种子(留空 = 真随机)」、「分隔」,结果会实时显示在下方,点击「复制结果」即可复制。Paste the list of integers to draw from, set "How many" to pick and tick "Unique" if a value may only be picked once. Leave "Seed" blank for a truly random draw, or enter a value to repeat the same draw; choose the "Separator" and click "Copy result" to copy the picks.
怎样输入多个整数?How do I enter several integers?
每行一个,或用空格、逗号、分号分隔。像 1,234,567 这样每 3 位一个逗号的写法按千位分隔读作一个数(所以 10,100 是 10100,要表示两个数请写 10 100);也可以用下划线分组(1_000)。负号可用 -、−(U+2212)或全角 -,全角数字也能识别。小数、科学计数法(1e3)或夹杂文字会报错并指出是第几个、完整显示那个值。One per line, or separated by spaces, commas or semicolons. A value with a comma every three digits, like 1,234,567, is read as one number with thousands separators (so 10,100 is 10100; write 10 100 for two values); underscores also group digits (1_000). Minus can be a hyphen, the Unicode minus (U+2212) or the fullwidth minus, and fullwidth digits work. Decimals, scientific notation (1e3) or stray text give an error naming the position and showing the whole value.
结果精确吗?Are the results exact?
精确。所有整数都按大整数(BigInt)逐位处理,不经过浮点,超过 2^53 的数(例如 9007199254740993)也不会被舍入。粘贴几千上万行也是线性处理,通常在几十毫秒内完成。Yes. Every value is handled as a big integer (BigInt) with no floating-point step, so numbers above 2^53 such as 9007199254740993 are never rounded. Pasting thousands of lines is processed in linear time, usually within tens of milliseconds.
种子有什么用?What is the seed for?
相同列表、个数和种子会得到相同抽取结果;留空则每次不同。The same list, count and seed always pick the same way; leave blank for a fresh draw.
「不重复」是什么意思?What does Unique mean?
每个位置最多被抽中一次。如果列表里本身有重复的值(例如 1 1 2),结果里仍可能出现两个 1;需要按值不重复,请先用「排序整数列表」勾选去重。Each position in the list is picked at most once. If the list itself repeats a value (1 1 2), the result can still contain two 1s; to make values unique, first use Sort Integers with Remove duplicates.
输入和输出是什么样的?What does the input and output look like?
例如在「从整数列表中抽取」中输入 1 ⏎ 2 ⏎ 3,「抽取个数」设为 1,「种子(留空 = 真随机)」设为 1,输出为:2(⏎ 表示换行)。For example, the Pick an Integer turns the input 1 ⏎ 2 ⏎ 3, "How many" set to 1, "Seed (blank = truly random)" set to 1 into: 2 (⏎ marks a line break).
有哪些选项可以调整?What options can I adjust?
「从整数列表中抽取」的设置:「抽取个数」默认 1;「种子(留空 = 真随机)」可留空;「分隔」可选 每行一个、空格、逗号、分号(默认 每行一个);可勾选:「不重复」、「千位逗号」。改动任一选项后结果会按新设置重新生成。Settings in the Pick an Integer — "How many" default 1; "Seed (blank = truly random)" optional; "Separator": One per line, Spaces, Commas, Semicolons (default One per line); tick boxes: "Unique", "Thousands commas". Changing any option regenerates the result with the new setting.
「从整数列表中抽取」免费吗?需要注册吗?Is the Pick an Integer free? Do I need an account?
「从整数列表中抽取」完全免费,无需注册或安装,打开网页即可使用,手机和电脑都能用;输入的内容只在你的浏览器本地处理。The Pick an Integer is completely free with no sign-up or install and works on phones and desktops; what you enter is processed only in your browser.