banner_i for in range entries count results append entries if and and

1
2
3
4
5
6
banner_i = 0
for i in range( 0, entries.count() ):
results.append( ( 0, entries[ i ] ) )
if i and i % 3 == 0 and banner_i < banners.count():
results.append( ( 1, banners[ banner_i ] ) )
banner_i += 1