Maximum Subarray Product Leetcode Javascript Problems