Re:Linked List Problems (2002) [pdf]
by microtherion on Sunday November 26, 2017 @04:58AM
(#15780206)
The second part of this confused me as well, because the algorithm only detects the existence of the cycle, not its length. However, once you know a node in the cycle (which this algorithm will provide), you simply go around the cycle once more and you have the length.
[ Parent
| on HN ]