Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Re: Another 'ode to backslash' ;-)

by hopes (Friar)
on Oct 02, 2001 at 23:00 UTC ( [id://116235]=note: print w/replies, xml ) Need Help??


in reply to Re: Another 'ode to backslash' ;-)
in thread Another 'ode to backslash' ;-)

There is an error in your code. See perldoc perlop
or see perlop

q/STRING/
'STRING'
A single-quoted, literal string. A backslash represents a
backslash unless followed by the delimiter or another backslash,
in which case the delimiter or backslash is interpolated.


So '\' don't is what you expect. You have to write '\\' instead.
Yeah, it's tricky. Note that
print '\\\machine';
is the same as
print '\\\\machine';
but not
print '\\machine';
You can use q;\\; if you want to obfuscate more.

Regards

Hopes

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (5)
As of 2024-03-28 13:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found