Get parameter by name

Greg Ewing greg.ewing at compaq.com
Mon Nov 8 12:17:19 CET 1999


Oleg Broytmann wrote:
> 
>    x = "ka"
> 
> how can I get the value of parameter, the name of which is in x ("ka", in
> this case)?

   foo = locals()[x]

Greg




More information about the Python-list mailing list