in reply to Re^4: Why does 'print shift sort @array' not work?
in thread Why does 'print shift sort @array' not work?
But that's a whole character longer . . . :) (But then again the square version requires hitting shift one less time so it has that going for it :)
print +(sort @array)[0]; print [sort @array]->[0];
Possibly could an interesting benchmark if anyone's so inclined: does slicing the value off the stack beat constructing the anonymous arrayref (which gets tossed immediately) then deref'ing, and what the falloff is as @array grows.
The cake is a lie.
The cake is a lie.
The cake is a lie.
|
|---|