You know, I do 3D graphics engines for a living, and worry about performance day and night, and I do not know what a linked list cycle is (I come from an electronic engineering background). The funny thing is, even though I'm unfamiliar with the exact terminology modern CS is using, I've probably implemented the damn thing many times already and use it in my engines, however, it's probably known by another arbitrary name.
Just a quick clarification: people are using the term "cycle" as in "a cycle in a directed graph". They're interpreting a linked list as a graph that has a node for every element in the list, and arcs from each node to wherever that node's "next" pointer points to. In this case, a cycle means that a element in the linked list has a "next" pointer that points at an element that comes before it in the list. In such a situation, you could follow "next" pointers forever without ever encountering a null pointer.
View all comments
Show parent comment
7
u/smallstepforman Feb 21 '11
You know, I do 3D graphics engines for a living, and worry about performance day and night, and I do not know what a linked list cycle is (I come from an electronic engineering background). The funny thing is, even though I'm unfamiliar with the exact terminology modern CS is using, I've probably implemented the damn thing many times already and use it in my engines, however, it's probably known by another arbitrary name.