title: Error: "x instance has no attribute y" when trying to inherit from class
body: <p>I can't really understand what I'm doing wrong, since when I try it in "small scale" and it is working there.</p>
  
  <p>I have a class named <code>Play()</code></p>
  
  <p>I goes like this:</p>
  
  <pre><code>class Play():
      def __init__(self):
          file = open("/home/trufa/Desktop/test", "r")
          self.word = random.choice(file.readlines()).rstrip()
          self.errAllowed = 7
          self.errMade = 0
          self.errList = []
          self.cheatsAllowed = 2##chetas not incrementing
          self.cheatsMade =0
          self.wordList = ["*"]*len(self.word) ##this one is the one I want to have available in another class
  </code></pre>
  
  <p>...</p>
  
  <p>Then I have another class called <code>Score()</code></p>
  
  <pre><code>class Score(Play):
      def __init__(self):
          self.initialScore = 0
  
      def letterGuess(self):
          self.initialScore += 1
          return self.errList
  </code></pre>
  
  <p>...</p>
  
  <p>I instantiated both:</p>
  
  <pre><code>game = Play()
  points = Score()
  </code></pre>
  
  <p>And if I do:</p>
  
  <pre><code>print points.letterGuess()
  </code></pre>
  
  <p>It gives me an error:</p>
  
  <pre><code>Traceback (most recent call last):
    File "/home/trufa/workspace/hangpy/src/v2.py", line 188, in &lt;module&gt;
      startGame()
    File "/home/trufa/workspace/hangpy/src/v2.py", line 134, in startGame
      print points.letterGuess()
    File "/home/trufa/workspace/hangpy/src/v2.py", line 79, in letterGuess
      return self.errList
  AttributeError: Score instance has no attribute 'errList'
  </code></pre>
  
  <p>I don't understand why since I can do this without any trouble:</p>
  
  <pre><code>class One():
      def __init__(self):
          self.list= [1,2]
  
  class Two(One):
      def meth(self):
          return self.list
  
  uan = One()
  tu = Two()
  
  print uan.list 
  print tu.meth() ## Both output [1,2]
  </code></pre>
  
  <p>I'm very new to OOP so I could be doing all kinds of silly mistakes but I can't figure out where! </p>
  
  <p>I <strong>think</strong> I have posted all the relevant code, but I you think the error might be elsewhere, I can provide it.</p>
  
  <p><sup>As I said I'm very new, so this might have nothing to do with inheritance I just think it called that when you get "something" from within another class (you must be shouting at the screen by now)</sup></p>