generated from mwc/lab_weather
for the fifth function - I used the previous function to help me code the count by using the len command that I used for the first function! Easy way to return the number of people who like a given color
This commit is contained in:
@@ -78,7 +78,8 @@ def count_people_who_like_color(people, color):
|
||||
>>> count_people_who_like_color(family, "orange")
|
||||
1
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
return len(people_who_like_color(people, color))
|
||||
|
||||
|
||||
def get_color_dict(people):
|
||||
"""Returns a dict showing how many people like each color.
|
||||
|
||||
Reference in New Issue
Block a user