why instance has no __name__ attribution in python?
<pre><code>&gt;&gt;&gt; class Foo:
...   'it is a example'
...   print 'i am here'
... 
i am here
&gt;&gt;&gt; Foo.__name__
'Foo'
&gt;&gt;&gt; Foo().__name__
Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in &lt;module&gt;
AttributeError: Foo instance has no attribute '__name__'
&gt;&gt;&gt; Foo.__doc__
'it is a example'
&gt;&gt;&gt; Foo().__doc__
'it is a example'
&gt;&gt;&gt; Foo.__dict__
{'__module__': '__main__', '__doc__': 'it is a example'}
&gt;&gt;&gt; Foo().__dict__
{}
&gt;&gt;&gt; Foo.__module__
'__main__'
&gt;&gt;&gt; Foo().__module__
'__main__'
&gt;&gt;&gt; myname=Foo()
&gt;&gt;&gt; myname.__name__
Traceback (most recent call last):
 File "&lt;stdin&gt;", line 1, in &lt;module&gt;
AttributeError: Foo instance has no attribute `__name__`
</code></pre>

<p>what is the reason instance has  no attribute  <code>__name__</code>?<br>
maybe it is ok that the <code>__name__</code> of instance-myname is  <code>myname</code>.<br>
would you mind  tell me more logical ,not the unreasonable grammar rules?</p>
