I was just interested in more options.
This is kind of old-school and amounts to the same thing as sticking an our ($a, $b); statement somewhere, but it's another option:
>perl -wMstrict -le "use List::Util qw/reduce/; use vars qw($a $b); ;; print reduce { $a * $b } 1..6; " 720
In reply to Re^4: Name "main::a" used only once: possible typo
by AnomalousMonk
in thread Name "main::a" used only once: possible typo
by szabgab
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |