Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: adding items, but with interim results

by AnomalousMonk (Abbot)
on Mar 30, 2013 at 23:36 UTC ( #1026309=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my @y = map { state $z = 0; $z += $_ } @x;
    
  2. or download this
    >perl -wMstrict -MData::Dump -lE
    "sub summer { return map { state $z = 0;  $z += $_; } @_; }
    ...
    
    ----------
    [0, 1, 3, 2]
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1026309]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (6)
As of 2014-10-01 22:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    What is your favourite meta-syntactic variable name?














    Results (40 votes), past polls