Tag: algorithm-and-data-strcuture

  • Continuous Subarray Sum

    Given an integer array nums and an integer k, return true if nums has a good subarray or false otherwise. A good subarray is a subarray where: Note that: Example 1: Input: nums = [23,2,4,6,7], k = 6 Output: true Explanation: [2, 4] is a continuous subarray of size 2 whose elements sum up to 6. let’s break down this code visually. The goal is to…