I was looking for a module that would give back an iterator and/or elements to work over a list in chunks. Wrote it once or twice in different places; forgot about it. Then needed it again few days ago. This time I put the work (closure based) in a local module. Nonetheless I tried to search CPAN.
Array::Iterator does not have seem to have the provision to specify chunk|step size; Parallel::Iterator seemed heavy and am not sure about &batch (even after reading pod). Searching CPAN some more, I finally found that &List::MoreUtils::natatime does what I am after.
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |