Linked List, Easy
Question
Given a linked list, return the node where the cycle begins. If there is no cycle, return null
.
Note: Do not modify the linked list.
Answer
|
|
Running time: O(n)
Anne.github.io
Given a linked list, return the node where the cycle begins. If there is no cycle, return null
.
Note: Do not modify the linked list.
|
|
Running time: O(n)