Is there any way to do this without using '__init__'?
<pre><code>class a(object):
    c=b()# how to call the b method 
    d=4
    def __init__(self):
        print self.c
    def b(self):
        return self.d+1

a()
</code></pre>

<p>how to call the 'b' method not in the <code>__init__</code> </p>

<p>thanks</p>

<p>the error is :</p>

<pre><code>Traceback (most recent call last):
  File "D:\zjm_code\a.py", line 12, in &lt;module&gt;
    class a(object):
  File "D:\zjm_code\a.py", line 13, in a
    c=b()# how to call the b method 
NameError: name 'b' is not defined
</code></pre>
