
[LeetCode] 1749. Maximum Absolute Sum of Any Subarray (Python)
·
알고리즘/LeetCode
난이도: MediumProblem Description You are given an integer array nums. The absolute sum of a subarray [numsl, numsl+1, ..., numsr-1, numsr] is abs(numsl + numsl+1 + ... + numsr-1 + numsr). Return the maximum absolute sum of any (possibly empty) subarray of nums. Note that abs(x) is defined as follows:If x is a negative integer, then abs(x) = -x.If x is a non-negative integer, then abs(x) = x. Probl..