javascript-algorithms
javascript-algorithms copied to clipboard
hare and tortoise algoritm of cycle detection in a linked list
Did not see the cycle detection algorithm on the list of algorithms for linked list and Floyd's Cycle detection algorithm is a very interesting and intuitive algorithm to do the same in O(1) space and O(n) time complexity so I added the hare-tortoise algorithm to the code. Hope it adds value to the repository