Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re (tilly) 1: (Golf) Fragment Reassembly

by tilly (Archbishop)
on May 03, 2001 at 05:21 UTC ( #77540=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub c{@r='';@r=map{$c=$_;map$c.$_,@r}@_ for 1..shift;@r}
    
    sub i{($t=pop)=~s/./.*\Q$&/gs;pop=~/$t/s}
    
  2. or download this
    sub assemble {
    my$n;{for(c($n++,map{split//}@_)){$v=$_;map{i($v,$_)||next}@_;return$_
    +}redo}
    }
    
  3. or download this
    print assemble(qw(oa af wf wa));
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (8)
As of 2016-09-29 09:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Extraterrestrials haven't visited the Earth yet because:







    Results (551 votes). Check out past polls.