title: Print key-value pairs of a dictionary in python
body: <p>How I can print key-value pairs in this situation:</p>
  
  <pre><code>a = [
  {"name": "Tom", "age": 10},
  {"name": "Mark", "age": 5},
  {"name": "Pam", "age": 7}
  ]
  
  search_name = 'Tom'
  
  for i in a:
     for key in i:
        if (i[key] == search_name):
             print (item for item in a).next()
        else:
             print 'No Name'
  </code></pre>
  
  <p>I don't want to see 'No name' message </p>