Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: and vs &&

by trwww (Priest)
on Feb 12, 2009 at 03:53 UTC ( [id://743223]=note: print w/replies, xml ) Need Help??


in reply to and vs &&

Hello,

It is possible to write relatively obfuscated Perl. But perl will will be happy do de-obfuscate it for you if you ask it to:

$ perl -e 'my $a=(1 == 1) && (0);print "$a\n";' 0 $ perl -MO=Deparse -e 'my $a=(1 == 1) && (0);print "$a\n";' my $a = 0; print "$a\n"; -e syntax OK $ perl -e 'my $a=(1 == 1) and (0);print "$a\n";' 1 $ perl -MO=Deparse -e 'my $a=(1 == 1) and (0);print "$a\n";' '???' if my $a = 1; print "$a\n"; -e syntax OK

regards,

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (6)
As of 2024-03-29 09:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found