Perl-Sensitive Sunglasses | |
PerlMonks |
Re^3: Why does this code think I'm trying to use symbolic references?by AnomalousMonk (Archbishop) |
on Jun 12, 2016 at 22:58 UTC ( [id://1165442]=note: print w/replies, xml ) | Need Help?? |
... I'm normally quite prodigious with my horizontal whitespace ...
Either prodigality or parsimony seem to work; e.g., print $n+4; also avoids the problem. Apparently it's only $n +4 that Perl looks at and says "Oh, of course: a unary plus!" ( Update: Per perlop, unary + and - have higher precedence than the binary operators. Give a man a fish: <%-{-{-{-<
In Section
Seekers of Perl Wisdom
|
|