Had trouble with the list comprehension part.

Went ahead and did it with a loop. Couldn't get the different syntax to work using a list comprehension for avgAgeByGender.
Based on my example code above, see if you can rewrite this with a list comprehension.... it's very similar.