in reply to RE: RE: RE: scalarmap - some new perl syntax
in thread scalarmap - some new perl syntax

Yes you are right!

Having an extra parameter on scalarmap is exactly equivalent to adding this parameter onto the front of the list you pass to reduce.

EG

$z = scalarmap { $a * $b } 1, 2..10; # is the same as use List::Util; $z = reduce { $a * $b } 1, 2..10;
All hail to perl's unfancy list flattening subroutine parameter passing!

This makes scalarmap completely redundant :-( It was fun inventing it though :-)