title: Printing a list of objects of user defined class
body: <p>So I have a class, called <code>Vertex</code>. </p>
  
  <pre><code>class Vertex:
      '''
      This class is the vertex class. It represents a vertex.
      '''
  
      def __init__(self, label):
          self.label = label
          self.neighbours = []
  
      def __str__(self):
          return("Vertex "+str(self.label)+":"+str(self.neighbours))
  </code></pre>
  
  <p>I want to print a list of objects of this class, like this:</p>
  
  <pre><code>x = [Vertex(1), Vertex(2)]
  print x
  </code></pre>
  
  <p>but it shows me output like this:</p>
  
  <pre><code>[&lt;__main__.Vertex instance at 0xb76ed84c&gt;, &lt;__main__.Vertex instance at 0xb76ed86c&gt;]
  </code></pre>
  
  <p>Actually, I wanted to print the value of <code>Vertex.label</code> for each object.
  Is there any way to do it?</p>