17
Vincent Deveaux
Last seen 4 years ago
Member for 11 years, 6 months, 16 days
Difficulty Normal
cpt += (visible[i] == True)
The count (lines 55-57) can be improved in a pythonic manner:
cpt=sum(1 if seen else 0 for seen in visible)
explanations:
we explore every value of visible (for seen in visible)
then make a list of 1s and 0s (1 if seen else 0)
finally, make the sum of
More