stripe(rows) returning a list of (row, is_highlighted) tuples using enumerate inside a comprehension.stripe(['a', 'b', 'c', 'd'])
[('a', True), ('b', False), ('c', False), ('d', True)]Indices 0 and 3 are multiples of three.
for i, row in enumerate(rows) works inside a comprehension.
The boolean expression itself can sit in the tuple.