Comment by binary132
1 year ago
Yes, that’s what I was saying:
for each group:
for i in steps of #groups:
assign item to this group
I think that’s a lot easier to comprehend than the modulus trick
1 year ago
Yes, that’s what I was saying:
for each group:
for i in steps of #groups:
assign item to this group
I think that’s a lot easier to comprehend than the modulus trick
For a lot of people the modulo approach isn't a "trick", it's just the intuitive way to split items into residue classes. And it's likely a little more cache-efficient.
well clearly your comment is meant to demonstrate that it’s a clumsy approach in a 1-indexed syntax, so perhaps a different technique would be more facile here… such as a counting method :)