develooper Front page | perl.fwp | Postings from March 2002

Re: TPR1 post-mortem

Thread Previous | Thread Next
Jason Purdy
March 8, 2002 05:41
Re: TPR1 post-mortem
Message ID:
Someone's gonna explain these, right?  Man, I love learning this kinda stuff. 
 Last "hole", I learned about pop vs. shift (saving two strokes) and after 
seeing this e-mail and playing around with Perl, I see that "-l" will take 
care of the newline stuff for me (so I don't have to add "$_\n" to my print 
statements [6 strokes there]).

Is that #*1.11%10 a number theory to get to the same number?  How did someone 
recognize that pattern? (my advanced calculus/comb math being a lil' rusty)  
What is \G ... $&?  Gotta dig out my Camel book again. ;)

Can't wait 'til next month!  Great job Dave & Jerome for managing this!



If memory serves me right, on Thursday 07 March 2002 20:36, Ton Hospel wrote:
> In article <a6913g$k06$1@post.home.lunix>,
> (Ton Hospel) writes:
> > Mm, I'm not sure all last results were processed, but the post-mortem
> > is on the site, so here we go.
> >
> > MTV was very close I see. With a simple transformation he's at 47:
> >
> > -l $_=pop;s;.;print,s,,$&*1.11%10if/\G../,eg;eg
> And here's a 46:
> -l $_=pop;s;.;print,s,,$&*1.11%10if/../g,eg;eg

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About