How to solve Leetcode 141. Linked List Cycle