News for hackers. Stuff that matters.
Re:Can you solve it? The Greplin programming challenge by leif on Friday October 08, 2010 @11:44PM (#1774290)
I can't read ruby, but here's something a little smarter than brute force in C (on its way to DP, but I couldn't be arsed to work out the recurrence so I just iterated until it stabilized): http://gist.github.com/617854
Re:Can you solve it? The Greplin programming challenge by dasil003 on Saturday October 09, 2010 @12:58AM (#1774370)
It looks similar to mine, but you got lucky (or unlucky depending on how you look at it) that the longest palindrome had an odd character count.

The confusing bits in the Ruby are actually just the definition of an even and odd palindrome finder, which are the same except for two seed values for where the first comparison is conducted and it's length.

Re:Can you solve it? The Greplin programming challenge by leif on Saturday October 09, 2010 @01:43AM (#1774449)
oh whoops nice catch thx