Python 어렵게 배우기 - Exercise 18: Names, Variables, Code, Functions
원문 : http://learnpythonthehardway.org/book/ex18.html 함수를 만들고 매개변수(parameter)를 넘겨 보자 (ex18.py) # this one is like your scripts with argv def print_two(*args): arg1, arg2 = args print "arg1: %r, arg2: %r" % (arg1, arg2) # ok, that *args is actually pointless, we can just do this def print_two_again(arg1, arg2): print "arg1: %r, arg2: %r" % (arg1, arg2) # this just takes one argument def print_one(..
더보기