modifing function's parameters global value

Steven Taschuk staschuk at telusplanet.net
Tue May 13 16:27:06 EDT 2003


Quoth Chad Netzer:
> On Tue, 2003-05-13 at 11:16, Federico wrote:
  [...]
> > there is no way to modify a parameter in a function? In C I used pointers...
> 
> There are ways, but doing things this way is considered awful practice. 
> Even in C, when it is done, it is mainly because C is less flexible
> about return types.
  [...]

A couple weeks ago, Jeff Epler wrote a nice post on the same
subject, looking at three typical examples of passing-a-pointer
technique in C(++) and the usual Python techniques for the same
problems:

    <http://groups.google.com/groups?th=5c54ac4ec68aeafa#link6>

-- 
Steven Taschuk                  staschuk at telusplanet.net
"Telekinesis would be worth patenting."  -- James Gleick





More information about the Python-list mailing list