Perl fixes this problem with an optional continue block at the end of a loop block. This block is always executed after any calls to next, which is Perls version of a C continue statement.