Inside for-loops and iterator methods like each
and map
the next
keyword in ruby will have the effect of jumping to the next iteration of the loop (same as continue
in C).
However what it actually does is just to return from the current block. So you can use it with any method that takes a block - even if it has nothing to do with iteration.