leetle

Daily challenge for 2026-03-03

427. Smallest Sum Above Threshold

Given an array of positive integers nums and a target integer k, find the minimum sum of any contiguous subarray that is greater than or equal to k. If no such subarray exists, return 0.

Example:
Input: nums = [2, 3, 1, 2, 4, 3], k = 7 Output: 7 (The subarray [4, 3] sums to 7).

Run this challenge interactively in Python or JavaScript when the app loads.