Array Based Leetcode Problems Javascript Interview