What you're looking at there is fudged collision detection (which I actually use in everything these days

). 4K isn't a great place to look for good coding examples btw

In the game there may be moving elements which want to collide with each other that are updated by the logic based on the delta in time (change in time). However, if the logic time step gets too big two elements might move so far that they pass right though each other. Imagine a bullet and alien. The bullet is moving - if the logic which moves it was stepped with 1000ms it might jump right past the alien and never intersect with it. The way the loop is above the time step is always small - meaning that no matter how much time is passed the logic is only updated in small sections. Logic tends to be cheaper than rendering (horrible generalisation) in this sort of simple game - so it doesn't hurt to call render often and makes the collision detection easy to implement and much more reliable.
The other way to do this which more reliable is swept collision detection when you work out the path of all the moving elements and determine where they cross based on time. However, this sort of collision is non-trivial and doesn't really suit 4K programming (or me generally for that matter).
Incidently, your rewrite:
1 2 3 4 5
| int diff = 0; for (int i=0;i<delta/10;i++) { diff+=10; } logic((delta % 10) + diff); |
essentially does this:
which is almost certainly what I had in place originally before noticing the collision problems.
Hope this helps,
Kev