title: Python: Modifying one attribute to each object in a list
body: <p>My question is basic and is maybe a duplicate but I haven't found the answer.</p>
  
  <p>I am looking for the most efficient (pythonic) way of adding 1 to the attribute <code>x</code> of all objects of a given list.</p>
  
  <pre><code>class Any(object):
     def __init__(self, x):
         self.x = x
  
  l = [Any(1), Any(-3), Any(1), Any(4), Any(6), Any(7), Any(3)]
  </code></pre>
  
  <p>Is there a better solution than (using list comprehension for example):</p>
  
  <pre><code>for i in l:
      i.x += 1
  </code></pre>