Two Pointer Leetcode Problems Javascript Interview