I don't want to spoil the fun with too much of an explanation. Become a winner by trying it for yourself.

Hopefully the result is almost as fun as the pleasure I had writing it.

sub p{print@_}$p="ITRS ZMNSGDQ ODQK GZBJDQ";$p=~y:ZA-Y:A-Z:;@a=split //,$p;@k=map{/\w/?'*':$_}@a;Z:until($v){p"$/\$$t: ",@k,$/;$n=int(rand (9))*100+100;p"Spin:\$$n. Guess letter, or phrase to solve$/";$g= <STDIN>;chomp($g=uc$g);if(length$g>1){if($g eq$p){$v++}else{$t=0}last Z}for(@k){if($g eq$_){p"Already used $g$/";next Z}}if($g=~/[AEIOUY]/ ){$t-=100;p"Vowel costs \$100$/";$n=0}$c=0;for($i=0;$i<@a;$i++){if($g eq$a[$i]){$t+=$n;$c++;$k[$i]=$a[$i]}}p"$c $g\'s.$/";$v++if join("",@k )eq$p}p@k,$/;if($v){p"Congrats, "}else{p"Wrong, "}p"win \$$t$/"

All it needs is Vanna White. Enjoy!!!

Dave

"If I had my life to do over again, I'd be a plumber." -- Albert Einstein


Technical discussion follows

Interesting to me is the fact that while this code runs fine (and even ran under strictures before I took out the 'my' declarations), it won't deparse using B::Deparse, at least under Perl 5.8.0 on Win32. I typically deparse a script by removing the shebang line, and then running it as, perl -MO=Deparse script >deparsed. That approach fails with 'Can't call method "isa" without a package or object reference at C:/indigoperl/perl/lib/Deparse.pm line 1080. Check failed--call queue aborted.'

Stumping B::Deparse is trivial if eval is used, or fork or something like that. But this obfu doesn't use any unusual trickery that I expected to be capable of stifling B::Deparse.

This being an obfu (though not a terribly obscure one at that), I consider the fact that it stumps B::Deparse a little added bonus.


In reply to Perl of Fortune by davido

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.