16/18 Comprehending Comprehensions



Error message:
threes_and_fives should contain 3, but doesn't.

threes_and_fives=[x%3==0 or x%5==0 for x in range(1,16)]


you might want to check the hint, you are going to need a slightly different list comprehension, from the hint:

list_name = [y for y in range]

the first y is what is going the be pushed into the list, for y in range. You want this, since you want to push y (or in your casex) into the list, and you can add a condition to this:

list_name = [y for y in range if condition]


thank you, I had the exact same code and exact same problem, I now know my problem...thanks!