intermediate
Challenge: range sums in constant time
Implement this from the stub. Hidden tests grade the behaviour you write, not the comments you leave.
Challenge: Range Sums in Constant Time
export class PrefixSums {
constructor(nums: number[]) {
// Your implementation here
}
rangeSum(left: number, inclusiveRight: number): number {
// Your implementation here
}
}challenge — implement from scratchCtrl+↵ submits · Ctrl+Shift+↵ runsstarter code