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

Re: I need a perl script to make every instance of a repeated word unique

by tilly (Archbishop)
on Jan 28, 2011 at 23:57 UTC ( #884953=note: print w/replies, xml ) Need Help??


in reply to I need a perl script to make every instance of a repeated word unique

The substitution that you will need is s/\bundefined\b/"undefined" . ++$count/eg.

perlop has instructions for how to use such substitutions (look for "s/PATTERN/REPLACEMENT"), and perlrun documents the -p and -e flags which are likely to prove very useful for you.

  • Comment on Re: I need a perl script to make every instance of a repeated word unique
  • Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (3)
As of 2016-10-01 22:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?






    Results (9 votes). Check out past polls.