Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^3: Comparing Lines within a Word List

by graff (Chancellor)
on Apr 27, 2016 at 10:07 UTC ( [id://1161620]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
        my $model = shift @words;
        my $regex = join( "", map{ ( /[rs]/ ) ? "[rs]" : $_ } split( /([rs
    +])/, $model ));
        next if ( $regex eq $model );  # skip if model has no "r" or "s"
        my @hits = grep /^$regex$/, @words;
        ...
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (4)
As of 2024-04-24 06:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found