Leetcode 307. Range Sum Query - Mutable
Support efficient point updates and range-sum queries on an integer array: update index to a new value and return the sum of nums[left..right]. With up to 3·10^4 operations and array size up to 3·10^4, the problem requires better than O(n) per operation (commonly solved with a segment tree or Fenwick tree for O(log n) updates/queries).
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
0
Hello Interview Premium
Your account is free and you can post anonymously if you choose.