Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine

Re^2: reset of match variables

by AnomalousMonk (Canon)
on Oct 03, 2011 at 22:25 UTC ( #929424=note: print w/replies, xml ) Need Help??

in reply to Re: reset of match variables
in thread reset of match variables

With warnings and strictures:

>perl -wMstrict -lne "$::SUM += /(\d+)/ && $1; END { print $::SUM } " foo123bar foo xxx111ccc xxx ^Z 234

Replies are listed 'Best First'.
Re^3: reset of match variables
by bart (Canon) on Oct 04, 2011 at 11:31 UTC
    Jeezes, who would want to use strict and a workaround for a one-liner??

      I write 550 character long one-liners (anything above that I convert to a script file), and I do often use strict in them.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2016-10-28 01:53 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (374 votes). Check out past polls.