Zig's Curious Multi-Sequence For Loops

from blog Loris Cro's Personal Website, | ↗ original
Zig has just gained new for loop syntax that allows you to iterate on multiple slices / arrays at the same time. In this blog post I'm going to explain in detail the rationale behind this choice, while also introducing you to a couple useful patterns that the syntax is meant to encourage.If you want to try it out, you will need an unstable build of Zig, which you can get from the downloads page.Basic...