News for hackers. Stuff that matters.
Re:Productive Programming by arethuza on Tuesday August 31, 2010 @12:12PM (#1649838)
The one I remember vividly was a bug in a student project - I was writing a set of tools to "compile" lambda calculus expressions to to various sets of combinators and gather statistics about the effectiveness of different sets of combinators (starting with SK).

For some reason any attempt to implement a Y-combinator for recursion was crashing and for a couple of days I had no idea what could be wrong - then sitting on a bus on the way to visit my sister I was looking at a cinema from the bus and the thought came into my head "it's your aggressive re-use of applicative nodes".

Sure enough next day I removed this attempt at an optimization and everything worked!

I've had a few experiences like that and I now know that if I find a really tricky bug the best strategy isn't to sit there all night looking at it but to go and get a decent nights sleep - there is a very good chance you will know the answer by the next morning.

There are no comments on this comment yet.