title: I'm getting a atrribute error for this particular program
body: <pre><code>class Parser(object):
  
      def __init__(self,tokens):
         self.tokens = tokens
         self.token_index = 0
  
      def parse(self):
  
         while self.token_index &lt; len(self.tokens):
             token_type = self.tokens[self.token_index][0]
             token_value = self.tokens[self.token_index][1]
             print(token_type,token_value)
             self.token_index += 1
  </code></pre>
  
  <p>This is the parser file</p>
  
  <p>This is the main file
  <a href="https://i.stack.imgur.com/52BRQ.png" rel="nofollow noreferrer">enter image description here</a></p>
  
  <p>This is the error
  <a href="https://i.stack.imgur.com/7kdIn.png" rel="nofollow noreferrer">enter image description here</a></p>
  
  <p>I have give the screenshots as I was facing error while postng my question so sorry for that
  Any rectification will be very helpful</p>