ProTip: A task running in a shell script's 'for' loop that are paused by signal TSTP (that is, hitting ^Z) and restarted (with 'fg' or '%') will keep going, but the loop will have been broken and not continue (bash behavior) or the command sequence will continue as though it had completed ('dash' and probably other Bourne shells behavior). I've tested in bash and dash.
This doesn't work when interrupted by ^Z:
$ for X in 1 2 3; echo Iteration $X; sleep 5; echo Iteration $X complete; done
$ (for X in 1 2 3; echo Iteration $X; sleep 5; echo Iteration $X complete; done)
This sort of thing doesn't happen often but when you're looping through commands that take ~6h to complete and find you've lost the output, it's frustrating. :)