Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: How to insert a "/" within a string?

by bimleshsharma (Beadle)
on Feb 21, 2012 at 11:06 UTC ( #955277=note: print w/ replies, xml ) Need Help??


in reply to Re: How to insert a "/" within a string?
in thread How to insert a "/" within a string?

This will also work...

my $string = 'ACOCOB'; $string =~ s/CO/C\/O/g; print "$string\n";


Comment on Re^2: How to insert a "/" within a string?
Download Code
Replies are listed 'Best First'.
Re^3: How to insert a "/" within a string?
by ikegami (Pope) on Feb 22, 2012 at 00:01 UTC
    Yes, but he intentionally avoided using "/" as a delimiter to avoid "leaning toothpick syndrome".

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2015-07-29 03:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (260 votes), past polls