Hi there,
How can I turn a string into a callable object/function?
I have a = 'len', and I want to do: if callable(eval(a)): print
"callable", but that doesn't quite work the way I want. :)
Regards,
Guillermo
Tweet |
|
Follow ups
group | python-list |
categories | python |
posted | Apr 21, '08 at 11:05a |
active | Apr 21, '08 at 11:57a |
posts | 4 |
users | 3 |
website | python.org |
site design / logo © 2022 Grokbase