Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: regex search for words with one digit

by tybalt89 (Monsignor)
on Sep 21, 2020 at 17:22 UTC ( [id://11122013]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl
    
    ...
    my $text = "John P5ete Andrew Richard58 Nic4k Le7on5";
    my @names = $text =~ /\b[^\W\d]*\d[^\W\d]*\b/g;
    print "@names\n";
    
  2. or download this
    P5ete Nic4k
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (6)
As of 2024-04-16 15:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found