When perl "sees" $_->[0], it assumes that the latter flavour is in force, and by the time it arrives to "moo\n" it's expecting to find an operator (e.g. a comma, or a concatenation dot, or whatever). On the other hand, using the block resolves this ambiguity towards the former print() flavour.
Flavio
perl -ple'$_=reverse' <<<ti.xittelop@oivalf
In reply to Re^3: print to a filehandle
by polettix
in thread print to a filehandle
by dk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |