[303]Range Sum Query - Immutable
【题目描述】
Given an integer array nums, find the sum of the elements between indices i and j (i ≤ j), inclusive.
Example:
Given nums = [-2, 0, 3, -5, 2, -1]
sumRange(0, 2) -> 1
sumRange(2, 5)
原创
2015-12-08 20:30:14 ·
228 阅读 ·
0 评论