Subarray Sum Problems

  • Subarray with Given Sum
    • The subarray sum problem, tries to find any contiguous subarray that sums up to a particular number
  • Zero Sum Subarrays
  • Longest Subarray with Sum K
    • Instead of any subarray, find the longest sub array
  • Smallest Subarray with Sum Greater Than a Given Value
    • find the smallest subarray whose sum is greater than a given value
  • Maximum Sum of Subarrays of Size k
  • Suffix Sum
    • we can calculate suffix sum instead of prefix sum
    • this calculates the sum from a particular index to the end of the array