title: Storing the class name in class variable without typing the name of the class?
body: <p>In an instance method of a python class, I know that we can get the class name via <code>self.__class__.__name__</code></p>
  
  <p>However, I'd like to store the name of a class in a class variable, without coding the name of the class.</p>
  
  <p>I know I can do this to get a class's name into a class variable:</p>
  
  <pre><code>class MyClass(object):
    pass
  MyClass._myname = MyClass.__name__
  </code></pre>
  
  <p>However, I have to code the string <code>MyClass</code> two times outside of the class definition, simply to get the class name into a class variable. In this case, that would be <code>"MyClass"</code>, which I could simply code as follows:</p>
  
  <pre><code>class MyClass(object):
    _myname = "MyClass"
  </code></pre>
  
  <p>But even that is redundant, given that I have to hard-code <code>"MyClass"</code> within the <code>MyClass</code> class.</p>
  
  <p>What I'd like is to somehow get a class's name into a class variable without coding the class's name, as follows:</p>
  
  <pre><code>class MyClass(object):
    _myname = ???? # where ???? is a statement which returns the class
                   # name, in which the string "MyClass" does not appear
  </code></pre>
  
  <p>Is this even possible?</p>