in reply to map vs. foreach

If you are not using the return, don't use a map.

That said I would write your example as:

while (my @fields = (getpwent)[6,7]) { print map "$_\n", @fields, ("-" x 80); }
(print is quite happy taking a list...)