Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: Multidimensional regular expressions

by Anonymous Monk
on Sep 20, 2005 at 21:27 UTC ( #493604=note: print w/replies, xml ) Need Help??


in reply to Multidimensional regular expressions

Here's an attempt a better syntax...
#set up our 2D array... $target[0] = "Do What I Mean Please."; $target[1] = "Red Fish, Blue Fish."; $target[2] = "One, Two, Three, Four."; $target[3] = "Alpha Bravo Charlie Delta"; @target =~ s/(ish)/ / /(Two)/ uc $a /e; # now @target is... # $target[0] = "Do What I Mean Please."; # $target[1] = "Red FISH, Blue Fish."; # $target[2] = "One, TWO, Three, Four."; # $target[3] = "Alpha Bravo Charlie Delta"; @target =~ s /ea/ZZ/ /lu/ZZ/ /hr/ZZ/; # now @target is... # $target[0] = "Do What I MZZn Please."; # $target[1] = "Red FISH, BZZe Fish."; # $target[2] = "One, TWO, TZZee, Four."; # $target[3] = "Alpha Bravo Charlie Delta";

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2021-02-28 00:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?