Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Answer: How do i escape a '/' character when using tr?

( #28841=categorized answer: print w/ replies, xml ) Need Help??

Q&A > strings > How do i escape a '/' character when using tr? contributed by merlyn

That's odd.
$count_slash = tr/\///;
works just fine in my copy of Perl. Or you can use an alternate delimiter:
$count_slash = tr#/##;

Comment on Answer: How do i escape a '/' character when using tr?
Select or Download Code
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (7)
As of 2014-09-16 21:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (48 votes), past polls