title: AttributeError : int object has no attribute
body: <pre><code>class Point(object):
      ''' A point on a grid at location x, y '''
  
      def __init__(self, x, y):
          self.X=x
          self.Y=y   
  
      def __str__(self):
          return "X=" + str(self.X), "Y=" + str(self.Y)
  
  
      def __add__(self, other):
          if not isinstance(other, Point):
              raise TypeError("must be of type point")
          x= self.X+ other.X
          y= self.Y+ other.Y
          return Point(x, y)
  
  p1= Point(5, 8)
  print p1 + [10, 12]
  </code></pre>
  
  <p>When trying to add list or tuple at RHS i.e. print p1 + [10, 12], I'm getting</p>
  
  <pre><code>attributeError: int object has no attribute
  </code></pre>
  
  <p>How can this problem be solved?</p>