Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^2: reading a value from a given text

by karlgoethebier (Abbot)
on Apr 07, 2015 at 19:29 UTC ( [id://1122733]=note: print w/replies, xml ) Need Help??


in reply to Re: reading a value from a given text
in thread reading a value from a given text

"...a different way of extracting "34"...

my $flag = grep { /(34)$/ } split / /, $string;

Update: I regret this crap. Had a bad day, or and it is to too late, sorry.

Update 2: my $flag = ( ( split / /, $string )[-1] == 34 );

Regards, Karl

«The Crux of the Biscuit is the Apostrophe»

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2024-03-28 19:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found