diff options
author | Guido van Rossum <guido@python.org> | 1998-10-24 13:15:28 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1998-10-24 13:15:28 (GMT) |
commit | c62cf36e7630c73a5bc2309430b836cd616bb718 (patch) | |
tree | 780cdce608a0f6684bb18c25217109b2f1b6b3c9 /Doc/tut/tut.tex | |
parent | 3fbe67abd14c6341a44c9715a32d0f01ff4f9432 (diff) | |
download | cpython-c62cf36e7630c73a5bc2309430b836cd616bb718.zip cpython-c62cf36e7630c73a5bc2309430b836cd616bb718.tar.gz cpython-c62cf36e7630c73a5bc2309430b836cd616bb718.tar.bz2 |
The last two example functions in the section about default argument
values (4.7.1) should return l, not a. Reported by Axel Boldt.
Diffstat (limited to 'Doc/tut/tut.tex')
-rw-r--r-- | Doc/tut/tut.tex | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Doc/tut/tut.tex b/Doc/tut/tut.tex index e16fc46..f975436 100644 --- a/Doc/tut/tut.tex +++ b/Doc/tut/tut.tex @@ -1171,7 +1171,7 @@ the arguments passed to it on subsequent calls: \begin{verbatim} def f(a, l = []): l.append(a) - return a + return l print f(1) print f(2) print f(3) @@ -1193,7 +1193,7 @@ def f(a, l = None): if l is None: l = [] l.append(a) - return a + return l \end{verbatim} \subsection{Keyword Arguments \label{keywordArgs}} |