title: Removing Cycle in Linked List
body: <p>Question: To find starting node of loop if cycle exists in linked list</p>
  
  <p>Approach:</p>
  
  <p>(1)Using Hare-Tortoise algorithm, find if cycle exists(No issues with this step)</p>
  
  <p>(2)Let P be the node where hare and tortoise meets.Let H be head pointer on linked list.Traverse one node at a time from H and P until they meet.</p>
  
  <p>Doubt: Logic behind (2). How does traversing one step at a time from H and P ensure that they will meet at the start of loop?</p>
  
  <p>References:</p>
  
  <p><a href="http://codingstories.com/2014/12/10/algorithm-linked-list-cycleii/" rel="nofollow">Problem and Solution</a></p>
  
  <p><a href="http://simplyexpressforfunalgorithms.blogspot.in/2014/06/removal-of-loops-from-singly-linked.html" rel="nofollow">Partially Explained Logic(Refer second approach in this blog)</a></p>