Linked List Problem In Leetcode Two Sum Solution