http://qs321.pair.com?node_id=1147123


in reply to limiting number of snmp requests

Sounds like a job for natatime from List::MoreUtils

the help says this :-

natatime EXPR, LIST Creates an array iterator, for looping over an array in chunks of +$n items at a time. (n at a time, get it?). An example is probably a better explanation than I could give in words. Example: my @x = ('a' .. 'g'); my $it = natatime 3, @x; while (my @vals = $it->()) { print "@vals\n"; } This prints a b c d e f g