I know I am a bit late for the postmortem party, but I was out for the
weekend.

On Sat, Jun 08, 2002 at 05:32:30AM -0000, Juho Snellman wrote:
> <[EMAIL PROTECTED]> wrote:
> >I slapped myself ten seconds into the post-mortem when I saw "lc=~y/aeiouy//".
> >The rest of it all, I haven't quite grasped yet, but I'm getting there.  I'm
> >just proud of myself for getting "-ap056"!
> 
> I've been slapping myself silly for not using -a (or /\S+/g, or even
> split). Would've gotten a 165 otherwise, saving a whopping 11 strokes.
> Ah well, that should clinch me the coveted "most amateurish mistake"
> award.

While we are confessing to our Moments of the Duh!, here's mine.

I never saw that I could use a subroutine to compute the counts for
the second line. I have until the end stuck myself like a glue to the
two (actually four) ungly variables to get and accumulate counts. And
to top it off, I had to waste a whopping 8 chars, for initializing two
of those variables.

$V=$T=0;
map{$V+=$v=y/aeiouy//,$T+=$t=s/\w/$&/g;sprintf"%-*s",y///c,"$v/$t"}

I could have gone ahead from my 197 to 185, just by using the sub.

Adding the obvious optimization of combining the two maps into one,
would have taken me to a respectable 178 (closer but not enough to
beat the superbeginners, Martin and Guillermo).

Also, I wish I didn't spend considerable time groking the problem.

However, I am not gonna complain. I did pretty well in my opinion,
considering the time I spent (I started playing almost at the end of
the third day and then only in bursts of intense golfing the following
days). After all, I did get the -ap056 and sprintf"%-*s" (although I
would have liked to get rid of the unsightly sprintf with a better
martian idiom [I can dream, can't I?]).

And, yes, this is my last tournament as a beginner. I hope to play as
a veteran next time.

/prakash
-- 
|As the trials of life continue to take their toll, remember that      |
|there is always a future in Computer Maintenance.                     |
|                -- National Lampoon, "Deteriorata"                    |

Reply via email to