@@ -225,16 +225,18 @@ msgid ""
225225"to keep thinking at a more abstract level. The :keyword:`pass` is silently "
226226"ignored::"
227227msgstr ""
228+ ":keyword:`pass` "
229+ "的另一个用处是可以在你写新的代码时当作函数或者条件体的占位符,这样你就可以在更抽象的层次来继续思考。:keyword:`pass` 会被默默的忽略掉。"
228230
229231#: ../../tutorial/controlflow.rst:243
230232msgid "Defining Functions"
231- msgstr "给函数定义 "
233+ msgstr "定义函数 "
232234
233235#: ../../tutorial/controlflow.rst:245
234236msgid ""
235237"We can create a function that writes the Fibonacci series to an arbitrary "
236238"boundary::"
237- msgstr "我们可以创建一个函数,这个函数写出斐波那契(Fibonacci)数列直到一个任意的边界值为止 ::"
239+ msgstr "我们可以创建一个将Fibonacci系列写到任意边界的函数 ::"
238240
239241#: ../../tutorial/controlflow.rst:265
240242msgid ""
@@ -243,6 +245,7 @@ msgid ""
243245"parameters. The statements that form the body of the function start at the "
244246"next line, and must be indented."
245247msgstr ""
248+ "关键字 :keyword:`def` 引入一个函数 *定义*。它必须后跟函数名称和带括号的形式参数列表。构成函数体的语句从下一行开始,并且必须缩进。"
246249
247250#: ../../tutorial/controlflow.rst:270
248251msgid ""
@@ -254,6 +257,9 @@ msgid ""
254257"browse through code; it's good practice to include docstrings in code that "
255258"you write, so make a habit of it."
256259msgstr ""
260+ "函数体的第一个语句可以(可选的)是字符串文字;这个字符串文字是函数的文档字符串或 :dfn:`docstring` 。(有关文档字符串的更多信息,请参阅"
261+ " :ref:`tut-docstrings` "
262+ "部分)有些工具使用文档字符串自动生成在线或印刷文档,或者让用户以交互式的形式浏览代码;在你编写的代码中包含文档字符串是一种很好的做法,所以要养成习惯。"
257263
258264#: ../../tutorial/controlflow.rst:277
259265msgid ""
0 commit comments