Quick and Painless Tutorial (cont) def hello_func(n = "beautiful"): """ this is a doc string """ print "hello %s world" % (n) # functions can be renamed and assigned to f = hello_func f = None # functions can be called with keyword arguments def f(a, b):... f(a = 1, b = 2) def cheesehop(kind, *arguments, **keyword):... # kind is a regular parameter # *arguments is a tuple of parameters # **keyword is a dictionary of keyword:value # more on lists: append, extend, insert, remove, pop, index, count, sort, reverse # list comprehensions [x for x in range(4) if x < 2]