Given a linked list with cycle, find the cycle.
Anonymous
It's a well known problem. You need to have two pointers one of which traverses the list with a double speed. The cycle is found if sometime after start the fast pointer crosses the slow.
Check out your Company Bowl for anonymous work chats.