Linked List Cycle
Problem
Given a linked list, determine if it has a cycle in it.
Example
Given -21->10->4->5
, tail connects to node index 1
, return true
Challenge
Follow up:
Can you solve it without using extra space?
Given a linked list, determine if it has a cycle in it.
Given -21->10->4->5
, tail connects to node index 1
, return true
Follow up:
Can you solve it without using extra space?