var or inout parm?

mh at mh at
Sun Dec 7 09:54:46 CET 2008

How can I make a "var" parm, where the called function can modify
the value of the parameter in the caller?

def f(x):
    x = x + 1

n = 1
# n should now be 2

Many TIA!!

Mark Harrison
Pixar Animation Studios

More information about the Python-list mailing list