I've always thought Floyd's tortoise and hare[0] algorithm was handy as it can find a cycle in a DAG with low memory usage.
[0] https://en.wikipedia.org/wiki/Cycle_detection#Floyd's_tortoi...
[0] https://en.wikipedia.org/wiki/Cycle_detection#Floyd's_tortoi...
I always thought it's a linked list algo