in reply to Re^4: Loop through array or filehandle
in thread Loop through array or filehandle

I.e.:

my $iter = create_iter(...); ... while (defined(my $line = $iter->())) { do_something_with($line); }


Give a man a fish:  <%-{-{-{-<

Replies are listed 'Best First'.
Re^6: Loop through array or filehandle
by Laurent_R (Canon) on Sep 30, 2016 at 22:13 UTC
    Yeah, that's exactly what I was thinking about, but I did not want to suggest anything without testing.