On the other hand, there's also a common tenetcommon tenet that says I ought to avoid deep nesting of conditions and loops if it's possible and reasonable to do so.
The reason I gave a little bit more in this code snippet than is strictly required to understand the use case is because I think the fact that the for
loop isn't really "tight" and that it performs a lot of processing is relevant to the style choice. To me, it makes the code feel somewhat sloppy and messy to have multiple areas scattered throughout it which bump the reader back to the beginning of the loop. In other words, it feels a lot like the good old GOTO
the good old GOTO
that everyone loves to hate on.