Maximum Subarray Product Leetcode Javascript Interview