IncredibleThings

导航

2018年4月24日 #

Range Sum Query - Immutable

摘要: Given an integer array nums, find the sum of the elements between indices i and j (i ≤ j), inclusive. Example: Note: num[i]存的是nums的前i-1个元素之和,反正前j个元素和减 阅读全文

posted @ 2018-04-24 10:04 IncredibleThings 阅读(105) 评论(0) 推荐(0) 编辑

LeetCode - Missing Number

摘要: Given an array containing n distinct numbers taken from 0, 1, 2, ..., n, find the one that is missing from the array. Example 1 Input: [3,0,1] Output: 阅读全文

posted @ 2018-04-24 09:33 IncredibleThings 阅读(92) 评论(0) 推荐(0) 编辑