declare variable name for method python code example
Example: python use variable name as variable
>>> foo = "bar"
>>> exec(foo + " = 'something else'")
>>> print bar
something else
>>>
>>> foo = "bar"
>>> exec(foo + " = 'something else'")
>>> print bar
something else
>>>