1111# Rafael Fontenelle <rffontenelle@gmail.com>, 2026
1212# Alpha Du <alphanow@gmail.com>, 2026
1313# Freesand Leo <yuqinju@163.com>, 2026
14+ # zhoubo, 2026
1415#
1516#, fuzzy
1617msgid ""
@@ -19,7 +20,7 @@ msgstr ""
1920"Report-Msgid-Bugs-To : \n "
2021"POT-Creation-Date : 2026-11-05 21:52+0000\n "
2122"PO-Revision-Date : 2026-09-13 18:06+0000\n "
22- "Last-Translator : Freesand Leo <yuqinju@163.com> , 2026\n "
23+ "Last-Translator : zhoubo , 2026\n "
2324"Language-Team : Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n "
2425"MIME-Version : 1.0\n "
2526"Content-Type : text/plain; charset=UTF-8\n "
@@ -900,7 +901,8 @@ msgid ""
900901" return len(s) # len('100101') --> 6"
901902msgstr ""
902903"def bit_length(self):\n"
903- " s = bin(self) # 二进制表示形式:bin(-37) --> '-0b100101'\\ n s = s.lstrip('-0b') # 移除开头的零和负号\n"
904+ " s = bin(self) # 二进制表示形式: bin(-37) --> '-0b100101'\n"
905+ " s = s.lstrip('-0b') # 移除开头的零和负号\n"
904906" return len(s) # len('100101') --> 6"
905907
906908#: ../../builtins/stdtypes.rst:502
@@ -1439,7 +1441,8 @@ msgstr ""
14391441" if n % P == 0:\n"
14401442" hash_value = sys.hash_info.inf\n"
14411443" else:\n"
1442- " # 费马小定理:pow(n, P-1, P) 等于 1,\\ n # 则 pow(n, P-2, P) 等于 n 除以 P 的余数的倒数。\n"
1444+ " # 费马小定理: pow(n, P-1, P) 等于 1,\n"
1445+ " # 则 pow(n, P-2, P) 等于 n 除以 P 的余数的倒数。\n"
14431446" hash_value = (abs(m) % P) * pow(n, P - 2, P) % P\n"
14441447" if m < 0:\n"
14451448" hash_value = -hash_value\n"
@@ -3053,7 +3056,9 @@ msgid ""
30533056"String literals that are part of a single expression and have only "
30543057"whitespace between them will be implicitly converted to a single string "
30553058"literal. That is, ``(\" spam \" \" eggs\" ) == \" spam eggs\" ``."
3056- msgstr "作为单一表达式组成部分,之间只由空格分隔的多个字符串字面值会被隐式地转换为单个字符串字面值。也就是说,``(\\ == \" spam eggs\" ``。"
3059+ msgstr ""
3060+ "作为单一表达式组成部分,之间只由空格分隔的多个字符串字面值会被隐式地转换为单个字符串字面值。 也就是说,``(\" spam \" \" eggs\" ) "
3061+ "== \" spam eggs\" ``。"
30573062
30583063#: ../../builtins/stdtypes.rst:1763
30593064msgid ""
@@ -3203,7 +3208,7 @@ msgstr ""
32033208msgid ""
32043209"Return a copy of the string with its first character capitalized and the "
32053210"rest lowercased. For example:"
3206- msgstr ""
3211+ msgstr "返回一个字符串副本,使其第一个字符为大写,其余字符均为小写。例如: "
32073212
32083213#: ../../builtins/stdtypes.rst:1863
32093214msgid ""
@@ -3212,6 +3217,10 @@ msgid ""
32123217">>> 'Njemačka starts With a non-ASCII digraph'.capitalize()\n"
32133218"'Njemačka starts with a non-ascii digraph'"
32143219msgstr ""
3220+ ">>> 'PYTHON IS AMAZING'.capitalize()\n"
3221+ "'Python is amazing'\n"
3222+ ">>> 'Njemačka starts With a non-ASCII digraph'.capitalize()\n"
3223+ "'Njemačka starts with a non-ascii digraph'"
32153224
32163225#: ../../builtins/stdtypes.rst:1870 ../../builtins/stdtypes.rst:2336
32173226msgid "See also :meth:`title`."
@@ -3641,6 +3650,11 @@ msgid ""
36413650"the Unicode Standard <https://www.unicode.org/versions/Unicode16.0.0/core-"
36423651"spec/chapter-4/#G91002>`_. For example:"
36433652msgstr ""
3653+ "如果字符串中的所有字符均为字母字符且至少包含一个字符,则返回 ``True``;否则返回 ``False``。字母字符是指 Unicode "
3654+ "字符数据库中定义为“Letter”的字符,即其通用类别属性为“Lm”、“Lt”、“Lu”、“Ll”或“Lo”的字符。请注意,这与 `Alphabetic"
3655+ " property defined in section 4.10 'Letters, Alphabetic, and Ideographic' of "
3656+ "the Unicode Standard <https://www.unicode.org/versions/Unicode16.0.0/core-"
3657+ "spec/chapter-4/#G91002>`_ 不同。例如:"
36443658
36453659#: ../../builtins/stdtypes.rst:2143
36463660msgid ""
@@ -4830,7 +4844,7 @@ msgstr ""
48304844
48314845#: ../../builtins/stdtypes.rst:2875
48324846msgid "See also :meth:`istitle` and :meth:`capitalize`."
4833- msgstr ""
4847+ msgstr "另请参阅 :meth:`istitle` 和 :meth:`capitalize`。 "
48344848
48354849#: ../../builtins/stdtypes.rst:2880
48364850msgid ""
@@ -5134,6 +5148,8 @@ msgid ""
51345148"These strings follow the same syntax and evaluation rules as :ref:`formatted"
51355149" string literals <stdtypes-fstrings>`, with the following differences:"
51365150msgstr ""
5151+ "这些字符串遵循与 :ref:`formatted string literals <stdtypes-fstrings>` "
5152+ "相同的语法和求值规则,但存在以下差异:"
51375153
51385154#: ../../builtins/stdtypes.rst:3067
51395155msgid ""
@@ -5180,6 +5196,10 @@ msgid ""
51805196"(:func:`repr`) by default. If an explicit conversion or format specifier is "
51815197"provided, this will override the default behaviour."
51825198msgstr ""
5199+ "当插值表达式中给出等号 ``'='`` 时,该表达式的文本会被追加到相关插值之前的字面字符串中,其中包括等号及其两侧的空白。该表达式的 "
5200+ ":class:`!Interpolation` 实例仍按常规方式创建,只是 "
5201+ ":attr:`~string.templatelib.Interpolation.conversion` 默认会被设为 "
5202+ "'``r``'(:func:`repr`)。如果显式给出了转换或格式规格,则会覆盖这一默认行为。"
51835203
51845204#: ../../builtins/stdtypes.rst:3099
51855205msgid "``printf``-style String Formatting"
@@ -5872,7 +5892,7 @@ msgstr "如果 :class:`bytearray` 需要缩小,超过 *size* 的字节将被
58725892msgid ""
58735893"If the :class:`bytearray` needs to grow, all new bytes will be set to null "
58745894"bytes."
5875- msgstr ""
5895+ msgstr "如果 :class:`bytearray` 需要扩展,所有新字节都将被设置为空字节。 "
58765896
58775897#: ../../builtins/stdtypes.rst:3514
58785898msgid "This is equivalent to:"
@@ -6684,8 +6704,8 @@ msgid ""
66846704" those byte values in the sequence ``b' \\ t\\ n\\ r\\ x0b\\ f'`` (space, tab, "
66856705"newline, carriage return, vertical tab, form feed)."
66866706msgstr ""
6687- "如果序列中所有字节都是 ASCII 空白符并且序列非空则返回 ``True``,否则返回 ``False``。ASCII 空白符就是字节值包含在序列 "
6688- "``b' \\\\ t\\\\ n\\\\ r\\\\ x0b\\\\ f'`` (空格,制表,换行, 回车,垂直制表,进纸) 中的字符。"
6707+ "如果序列中所有字节都是 ASCII 空白符并且序列非空则返回 ``True`` ,否则返回 ``False`` 。 ASCII "
6708+ "空白符就是字节值包含在序列 ``b' \\ t\\ n\\ r\\ x0b\\ f'`` (空格、制表、换行、 回车,垂直制表,进纸) 中的字符。"
66896709
66906710#: ../../builtins/stdtypes.rst:4183
66916711msgid ""
@@ -7909,6 +7929,10 @@ msgid ""
79097929":mod:`collections` module.) See :ref:`time-complexity` for the costs of the "
79107930"various set operations."
79117931msgstr ""
7932+ ":dfn:`set` 对象是由互不相同的 :term:`hashable` "
7933+ "对象组成的无序集合。常见用途包括成员检测、去除序列中的重复项,以及计算交集、并集、差集和对称差集等数学运算。(其它容器请参阅内置的 "
7934+ ":class:`dict`、 :class:`list` 和 :class:`tuple` 类,以及 :mod:`collections` "
7935+ "模块。)各种集合运算的开销请参阅 :ref:`time-complexity`。"
79127936
79137937#: ../../builtins/stdtypes.rst:5103
79147938msgid ""
@@ -8179,6 +8203,8 @@ msgid ""
81798203":meth:`~set.remove`, and :meth:`~set.discard` methods may be a set. In this"
81808204" case, an equivalent frozenset is searched for."
81818205msgstr ""
8206+ "请注意,:meth:`~object.__contains__`、:meth:`~set.remove` 和 :meth:`~set.discard` "
8207+ "方法的 *elem* 参数可以是集合。在这种情况下,系统会搜索一个等价的 frozenset。"
81828208
81838209#: ../../builtins/stdtypes.rst:5300
81848210msgid ""
@@ -8205,6 +8231,10 @@ msgid ""
82058231":mod:`collections` module.) See :ref:`time-complexity` for the costs of the "
82068232"various dictionary operations."
82078233msgstr ""
8234+ ":term:`mapping` 对象将 :term:`hashable` 值映射到任意对象。映射对象是可变的。目前仅有一种标准映射类型,即 "
8235+ ":dfn:`dictionary`。(对于其他容器,请参阅内置类 :class:`list`、:class:`set` 和 "
8236+ ":class:`tuple`,以及 :mod:`collections` 模块。)有关各种字典操作的开销,请参阅 :ref:`time-"
8237+ "complexity`。"
82088238
82098239#: ../../builtins/stdtypes.rst:5327
82108240msgid ""
@@ -8239,7 +8269,7 @@ msgstr ""
82398269
82408270#: ../../builtins/stdtypes.rst:5345
82418271msgid "Use a dict comprehension: ``{x: x ** 2 for x in range(10)}``"
8242- msgstr ""
8272+ msgstr "使用字典推导式:``{x: x ** 2 for x in range(10)}`` "
82438273
82448274#: ../../builtins/stdtypes.rst:5346
82458275msgid ""
@@ -8573,7 +8603,7 @@ msgstr "返回由字典值组成的一个新视图。参见 :ref:`视图对象
85738603msgid ""
85748604"An equality comparison between two distinct ``dict.values()`` views will "
85758605"always return ``False``, even for views of the same dictionary::"
8576- msgstr ""
8606+ msgstr "对两个不同的 ``dict.values()`` 视图进行相等性比较时,无论这些视图是否属于同一个字典,结果始终为 ``False``:: "
85778607
85788608#: ../../builtins/stdtypes.rst:5559
85798609msgid ""
@@ -11239,7 +11269,7 @@ msgstr "method -- 方法"
1123911269
1124011270#: ../../builtins/stdtypes.rst:6291
1124111271msgid "code"
11242- msgstr "code"
11272+ msgstr "code -- 代码 "
1124311273
1124411274#: ../../builtins/stdtypes.rst:6291
1124511275msgid "code object"
0 commit comments