title: How do I pass a method as a parameter in Python
body: <p>Is it possible to pass a method as a parameter to a method?</p>
  
  <pre><code>self.method2(self.method1)
  
  def method1(self):
      return 'hello world'
  
  def method2(self, methodToRun):
      result = methodToRun.call()
      return result
  </code></pre>