1. Maximum Product Subarrayhistorical

    Given an integer array nums, find the contiguous subarray with the largest product (the subarray contains at least one number) and return that product.

  2. Maximum Subarrayhistorical

    Given an integer array nums, find the contiguous subarray with the largest sum (the subarray contains at least one element) and return its sum.