update tutorial function with more appropiate one from Eric Smith
This commit is contained in:
parent
dbd2f6d8a9
commit
a436878419
|
@ -445,8 +445,8 @@ called with an arbitrary number of arguments. These arguments will be wrapped
|
|||
up in a tuple. Before the variable number of arguments, zero or more normal
|
||||
arguments may occur. ::
|
||||
|
||||
def fprintf(file, template, *args):
|
||||
file.write(template.format(args))
|
||||
def write_multiple_items(file, seperator, *args):
|
||||
file.write(seperator.join(args))
|
||||
|
||||
|
||||
.. _tut-unpacking-arguments:
|
||||
|
|
Loading…
Reference in New Issue