Nit: all the helpers use `+= 1` instead of `++` (but we use `++` in the main loop)