Skip to content

Ariefah Shalihah

  • Home
  • About

How to call a function by its name as a string in Python

Use eval()

Use getattr()



how-to-call-a-function-by-its-name-as-a-string-in-python

Categories PYTHON
Post navigation
How to calculate the sum of every column in a NumPy array in Python
How to call a parent class constructor in Python

Recent Posts

  • How asynchronously call methods in Python
  • How get a function name as a string in Python
  • How pretty print a JSON file in Python
ariefahshalihah