def func(output=''): output(output=output)
Naturally, I get 'str' object is not callable. Is there a way to tell func that the first output is actually a function? (like in C++, ::output(output) )
You could use a default argument: def func(output='', output_fn=output): output_fn(output=output)
Kent -- http://mail.python.org/mailman/listinfo/python-list