Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Prime Time for an Obfuscation

by liverpole (Monsignor)
on Apr 16, 2007 at 03:07 UTC ( [id://610251]=obfuscated: print w/replies, xml ) Need Help??

With all the prime number fun going on over here, now seems a good chance to dust off and present an obfuscation that just needed a little polishing up.

Given a positive integer argument, this program will display all of its prime factors.

$;=pop;{$.= 0;map{$;%$_ or$.||=$_}2 ..sqrt$;;;+ $.||die$;-j .$/;warn$.. $/;$;/=$.;n until+redo}

s''(q.S:$/9=(T1';s;(..)(..);$..=substr+crypt($1,$2),2,3;eg;print$..$/

Replies are listed 'Best First'.
Re: Prime Time for an Obfuscation
by wulvrine (Friar) on Apr 16, 2007 at 12:24 UTC
    Great job!! ++
    Fun to play with putting in numbers like birthdays etc lol :)
    As always, you are the master of obfu's

    s&&VALKYRIE &&& print $_^q|!4 =+;' *|
Re: Prime Time for an Obfuscation
by Ray Smith (Beadle) on Apr 16, 2007 at 12:22 UTC
    Nice job - as usual!
Re: Prime Time for an Obfuscation
by Anonymous Monk on Jul 29, 2007 at 23:49 UTC
    Did someone have trouble running it against this number: 1234567890123111? 5.8.8 on MSWin32

      It tries to create a list containing 2..sqrt(1234567890123111). So it starts to allocate 33.5M entries, taking a long time to spin as much RAM into place as it can, before it (I presume) dies (having caused way too much other stuff to swap out). Is that what you mean by "problem"? :)

      - tye        

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2024-06-20 18:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuli‥ 🛈The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.