These are the results of yesterday's Ruby Golf in London.
The exercise focused on passing all nine holes without coming with
unreadable, and unmaintainable code.
More information below:
----- Forwarded Message -----
From: Andrew McDonough <
and...@andrewmcdonough.co.uk>
To: London Ruby Users Group <
ch...@lists.lrug.org>
Sent: Tuesday, May 10, 2011 3:03 PM
Subject: Re: [LRUG] ShRUG Golf update
Thanks James. I'm glad that ShRUG enjoyed it. We were a bit short on
time at LRUG, with less than an hour available for coding. Four teams
completed the course, and our winner was Tomasz Wegrzanowsk (@t_a_w),
who was working on his own, and managed 704 characters
(
http://j.mp/lbcXV2). Second place was @zuppr, @jamiemill @morticed
and @aanand who came a close second in with 843 chars
http://j.mp/mBjfJU, third place was @danlucraft, @nfelger, Jordi,
Dan, Tony, Steve and Keith who completed the course in 883 chars
http://j.mp/jHhbWU and finally one other anonymous team completed the
course with 1208 characters (if this was you, please let us know who
you are). The winner, Tomasz (
http://j.mp/lSsmJd), was presented with
a trophy (
http://j.mp/iRFwGP) and the second placed team got medals.
There are still four medals left, which I will award at the next LRUG
to the four people who produce the best solutions (not necessarily the
shortest ones), so there's still something to play for if you didn't
come along on the evening.
There appears to have been a lot of work done since to get the
character counts down even further, in particular from Paul Battley
with some help from Tom Stuart. Their commit log is worth looking
through:
https://github.com/threedaymonk/rubygolf/commits/master
They got the solution down to 654 characters, before realising they
could exploit my "whitespace isn't counted" rule to encode their
solution in spaces and newlines, and then simply decode and exec.
This brought the solution down to 37 characters. He gets one of the
four medals. Genius:
https://github.com/threedaymonk/rubygolf/blob/master/lib/golf.rb
I have put the introductory presentation I made up on heroku:
http://rubygolf-presentation.heroku.com
Skills Matter have published some photos of the evening:
http://www.flickr.com/photos/skillsmatter/5704350908/in/set-72157626683669388/
I will follow up later with some analysis of the solutions and some of
the tricks and techniques used, but for now, you can look through the
various solutions that were submitted:
https://github.com/andrewmcdonough/rubygolf/network
Congratulations to ShRUG - you guys did really well completing the
course with so few characters.
Andrew
---
Andrew McDonough
CTO, Tribesports
http://tribesports.com