Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: regex to extract value from a string (updated)

by AnomalousMonk (Archbishop)
on Jul 01, 2020 at 07:10 UTC ( [id://11118752]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    c:\@Work\Perl\monks>perl -wMstrict -le
    "for my $string (qw(
    ...
    '50.10-d557_8' -> '8'
    '50.10-d557_20' -> '20'
    '50.10-d557_123' -> '123'
    
  2. or download this
    c:\@Work\Perl\monks>perl -wMstrict -e
    "use Data::Dump qw(dd);
    ...
    
    ("_", undef, 0)
    '_' parse failed
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2024-04-19 09:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found