Fast And Slow Pointers
Normally fast pointer can go 2x than slow pointer. Useful when dealing with cyclic linked list
Ways to identity
- Dealing with a loop in linkedlist or array Floyd's Loop detection
- Identify a position of an element in the array
Normally fast pointer can go 2x than slow pointer. Useful when dealing with cyclic linked list
Ways to identity