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

A First - Please Comment

by r.joseph (Hermit)
on Dec 05, 2000 at 08:29 UTC ( [id://44938]=obfuscated: print w/replies, xml ) Need Help??

I realize that this isn't very obfuscated at all, and I am not posting it as a show-off: instead, I want to learn more about obfuscation and figured if I posted it I would get some help. So PLEASE, tear it apart - just be nice :-).
$=-=(1<<6)-4;while(<DATA>){@.=split/#/;for(@.){ $;[$=].=$_;$=++;}}for(@;){print chr hex;}__DATA__ 4a#75#73#74#20#41#6e#6f#74#68#65#72 20#50#65#72#6c#20#48#61#63#6b#65#72

Replies are listed 'Best First'.
Re: A First - Please Comment
by nashdj (Friar) on Dec 05, 2000 at 16:28 UTC
    Personally I like being as short as possible :)

    $/=-1,print map(chr hex,split(/#|\n/,<DATA>))

    Unfortunately short in this case is rather readable, so its not so great.

    I really like your use of $= and $; they really play tricks on the eyes.

    I would recommend that you

    • Abuse and confuse with map
    • Try encoding your data in different ways, it gets very familiar seeing japh text in decimal and hex :)
    • Throw in a couple of naked blocks just for the sake of it
    • Venture deeper into perl, and use things that you have never seen before, and mignt never use again. But you would be suprised, I personally find this a great way to learn the guts of perl.
    - nashdj

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (5)
As of 2024-04-18 21:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found