http://www.perlmonks.org?node_id=1046955


in reply to Eliminating "used only once" warnings from List::Util::reduce

This is the type of bug that makes Perl enormously interesting for me. Here's my last attempt:
#!/usr/bin/perl -l use strict; use warnings; use List::Util qw/reduce/; our($a, $b) = @_; my $reduce = reduce { $a + $b; } 1, 2, 3, 4; print $reduce;