Introduction To Python - Learn Python the hard way v2.0
voteup image
0

In ex18, we write a function which uses a strange syntax for it's argument.
def print_two(*args):

I think this is used because it packs all the arguments it recieves into the 'args' list. I don't understand, why do we need to do this if Python is weakly typed language? Why not simply use a single variable name to accept all the parameters to that function?

asked Oct 13, 2011

http://twitter.com/ragi_2's image

http://twitter.com/ragi_2

0 Answers:
Provide an answer to this question.
This editor supports the markdown format. Please visit this page, If you are not familiar with Markdown.

Recent Course Updates: