Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python get function from string name

module = __import__('foo')
func = getattr(module, 'bar')
func()
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #python #function #string
ADD COMMENT
Topic
Name
3+1 =