Skip to content

Intersection of Two Linked Lists ​

Intersection of Two Linked Lists

Find the point at which two linked lists intersect

Approach ​

  • Keep two pointers for each list.
  • When pointer A completes list A, it traverses list B.
  • When pointer B completes list B, it traverses list A.
  • They both will meet at intersection, or will complete 2 traversals and meet at null.

Remarks ​