title: Defining class functions inside class functions: Python
body: <p>I have a code in which I want to defina a class function inside a class function. Here's a simpler example of what I want to do. The goal of this program is to print 4.</p>
  
  <pre><code>&gt;&gt;&gt; class bluh:
  ...     def haha(self):
  ...             print 3
  ...     def __init__(self):
  ...             def haha(self):
  ...                     print 4
  ... 
  &gt;&gt;&gt; x = bluh()
  &gt;&gt;&gt; x.haha()
  3
  </code></pre>
  
  <p>How should I actually write this program to do what I want?</p>