88# xiao xu <[email protected] >, 201899101011+ # Junkai Shao <[email protected] >, 201811121213# Freesand Leo <[email protected] >, 20181314# Henry Zhu <[email protected] >, 2018@@ -45,27 +46,27 @@ msgstr "列表的更多特性"
4546msgid ""
4647"The list data type has some more methods. Here are all of the methods of "
4748"list objects:"
48- msgstr "列表数据类型还有更多的方法 。这里是列表对象方法的清单:"
49+ msgstr "列表数据类型还有很多的方法 。这里是列表对象方法的清单:"
4950
5051#: ../../tutorial/datastructures.rst:22
5152msgid ""
5253"Add an item to the end of the list. Equivalent to ``a[len(a):] = [x]``."
53- msgstr "添加一个元素到列表的末尾 。相当于 ``a[len(a):] = [x]`` 。"
54+ msgstr "在列表的末尾添加一个元素 。相当于 ``a[len(a):] = [x]`` 。"
5455
5556#: ../../tutorial/datastructures.rst:28
5657msgid ""
5758"Extend the list by appending all the items from the iterable. Equivalent to"
5859" ``a[len(a):] = iterable``."
59- msgstr "通过附加iterable中的所有项来扩展列表 。相当于 ``a [len(a): ] = iterable`` 。"
60+ msgstr "使用可迭代对象中的所有元素来扩展列表 。相当于 ``a[len(a): ] = iterable`` 。"
6061
6162#: ../../tutorial/datastructures.rst:35
6263msgid ""
6364"Insert an item at a given position. The first argument is the index of the "
6465"element before which to insert, so ``a.insert(0, x)`` inserts at the front "
6566"of the list, and ``a.insert(len(a), x)`` is equivalent to ``a.append(x)``."
6667msgstr ""
67- "在一个给定的位置插入一个项目。第一个参数是要插入位置之前的一个索引 ,所以 ``a.insert(0,x) `` 插入在列表头部, "
68- "``a.insert( len(a),x) `` 等同于 ``a.append(x) `` 。"
68+ "在给定的位置插入一个元素。第一个参数是要插入的元素的索引 ,所以 ``a.insert(0, x) `` 插入在列表头部, "
69+ "``a.insert( len(a), x) `` 等同于 ``a.append(x) `` 。"
6970
7071#: ../../tutorial/datastructures.rst:43
7172msgid ""
@@ -82,8 +83,8 @@ msgid ""
8283"that position. You will see this notation frequently in the Python Library "
8384"Reference.)"
8485msgstr ""
85- "删除列表中给定位置的元素并返回它。如果没有给定位置,``a.pop()`` 将会删除并返回列表中的最后一个元素。( *i* "
86- "两边的方括号表示这个参数是可选的,而不是要你输入方括号。你会在 Python 参考库中经常看到这种表示法 )。"
86+ "删除列表中给定位置的元素并返回它。如果没有给定位置,``a.pop()`` 将会删除并返回列表中的最后一个元素。( 方法签名中 *i* "
87+ "两边的方括号表示这个参数是可选的,而不是要你输入方括号。你会在 Python 参考库中经常看到这种表示方法 )。"
8788
8889#: ../../tutorial/datastructures.rst:60
8990msgid "Remove all items from the list. Equivalent to ``del a[:]``."
@@ -93,7 +94,7 @@ msgstr "删除列表中所有的元素。相当于 ``del a[:]`` 。"
9394msgid ""
9495"Return zero-based index in the list of the first item whose value is equal "
9596"to *x*. Raises a :exc:`ValueError` if there is no such item."
96- msgstr "返回列表中第一个值为 *x* 的元素的索引(索引从 *0* 开始)。如果没有这样的元素将会报错 :exc:`ValueError` "
97+ msgstr "返回列表中第一个值为 *x* 的元素的从零开始的索引。如果没有这样的元素将会抛出 :exc:`ValueError` 异常。 "
9798
9899#: ../../tutorial/datastructures.rst:69
99100msgid ""
@@ -102,7 +103,8 @@ msgid ""
102103" list. The returned index is computed relative to the beginning of the full"
103104" sequence rather than the *start* argument."
104105msgstr ""
105- "可选参数 *start* 和 *end* 是切片符号,用于搜索出指定的列表子序列。返回的索引是相对于原列表计算的,而不是 *start* 参数。"
106+ "可选参数 *start* 和 *end* 是切片符号,用于将搜索限制为列表的特定子序列。返回的索引是相对于整个序列的开始计算的,而不是 *start* "
107+ "参数。"
106108
107109#: ../../tutorial/datastructures.rst:78
108110msgid "Return the number of times *x* appears in the list."
0 commit comments