Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Comment on

( #3333=superdoc: print w/ replies, xml ) Need Help??

Try running this in an xterm window!


#!/usr/bin/perl -w
sub d($){defined($        _[             0])}sub p(        $){print    @_}sub r
         ($$)            {int            $_[0]+rand($_     [1]-$_[0    ]+1)}$|=
         016;            my$a            =2;sub c{p"\e"    ."[H";;p    "\e[J";}
         open           (Y,$0)            ;my(    @y,$y)     ;for        (;;)
         {&d(          $y=(<Y>)           ) or    last;;     push        @y ,
         $y.(         ' '   x80           )} $SIG{INT}=      sub{c;exit};c;my
         $b=0        ;;;    for(;         ;){my($r,$c)       =(r(1,@y),r(1,80
         ));;       my$k=(substr($        y[$r-              1],$        c-1,
 1));;   ;;;;      printf"\e[%d;".        "%d".              "H".        "\e"
 ."[1"   .";"     ."7;"       ."%s"       ."m".              "%s"        ."".
 "\e[0m",$r,    $c,r(30,    37),$k if   $k ne" ";          }return;   ;__END__;
    __Just_    _Another_    PerlHacker  by_John_C          _Norton_   8/17/2005


Downloadable code:
#!/usr/bin/perl -w sub d($){defined($ _[ 0])}sub p( $){print + @_}sub r ($$) {int $_[0]+rand($_ [1]-$_[0 + ]+1)}$|= 016; my$a =2;sub c{p"\e" ."[H";;p + "\e[J";} open (Y,$0) ;my( @y,$y) ;for + (;;) {&d( $y=(<Y>) ) or last;; push + @y , $y.( ' ' x80 )} $SIG{INT}= sub{c;exi +t};c;my $b=0 ;;; for(; ;){my($r,$c) =(r(1,@y) +,r(1,80 ));; my$k=(substr($ y[$r- 1],$ + c-1, 1));; ;;;; printf"\e[%d;". "%d". "H". + "\e" ."[1" .";" ."7;" ."%s" ."m". "%s" + ."". "\e[0m",$r, $c,r(30, 37),$k if $k ne" "; }return; +;__END__; __Just_ _Another_ PerlHacker by_John_C _Norton_ +8/17/2005

"download section" added by holli


In reply to Sparkling Japh by liverpole

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!
  • 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, 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, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • Outside of code tags, you may need to use entities for some characters:
            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.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others meditating upon the Monastery: (8)
    As of 2014-12-18 04:22 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      Is guessing a good strategy for surviving in the IT business?





      Results (41 votes), past polls