News for hackers. Stuff that matters.
Re:The Tortoise and The Hare: Loops in Linked Lists by tokenrove on Saturday December 21, 2013 @01:13PM (#6947362)
This question seems to come up often enough. It came up in an interview I did a little while ago; I was delighted since I am a big fan of the Tortoise and the Hare algorithm (I think I originally read about it in The Connection Machine by Hillis, which is a great read in general).

I think it's a good interview question even if you're not familiar with it, because while you might not come up with the algorithm, it shows how the interviewee might reason about linked lists, and ask about what trade-offs you're looking for.

Re:The Tortoise and The Hare: Loops in Linked Lists by CoryG89 on Saturday December 21, 2013 @01:21PM (#6947396)
I agree, they mentioned something along the same lines while I was coming up with my horrible attempts. I really like the algorithm as well.