>>> def foo((a, b, c)):
... print c
... print a
... print b
...
>>> parameters = ('apple', 'bear', 'cat')
>>> foo(parameters)
cat
apple
bear
The proper way to call the function foo is with a tuple of three elements. When the function is called, the
elements are assigned to different local variables within foo.
... print c
... print a
... print b
...
>>> parameters = ('apple', 'bear', 'cat')
>>> foo(parameters)
cat
apple
bear
The proper way to call the function foo is with a tuple of three elements. When the function is called, the
elements are assigned to different local variables within foo.
Comments
Post a Comment
https://gengwg.blogspot.com/