python string to variable
example:
exec:执行字串语句
>>> l=[12,3,4,4]
>>> s = 'l.append(10)'
>>> exec(s)
>>> s
'l.append(10)'
>>> l
[12, 3, 4, 4, 10]
>>>
eval:让字串变成与之对应的变量名
>>> str = 'good'
>>> good = 'hello!world'
>>> eval(str)
'hello!world'
>>> good
'hello!world'