title: Python, Filter a List of Objects, but return a specific attribute?
body: <p>Suppose I have a list of Person objects, which have an age and room_number attribute, and I have written a check() function, which returns True, if person.age() and person.room_number() are satisfactory, False otherwise.</p>
  
  <p><code>filter(check, list_of_people_objects)</code> would return a list of Person objects which satisfies the criteria of <code>check()</code> </p>
  
  <p>However, my question is, is there a way of returning a list of each approved Person's room number without iterating through the list twice, like so without using list comprehension?
  So filtering, but returning a more specific attribute of the iterable.</p>
  
  <p><code>map(lambda x: x.room_number(), filter(check, list_of_people_objects))</code></p>