Solving Range Sum Query Mutable in go. Please try yourself first to solve the problem and submit your implementation to LeetCode before looking into solution.

Problem Description

Example:

Given nums = [1, 3, 5]

sumRange(0, 2) -> 9
update(1, 2)
sumRange(0, 2) -> 8

Note:

Given nums = [1, 3, 5]

sumRange(0, 2) -> 9  
update(1, 2)  
sumRange(0, 2) -> 8  

See the full details of the problem Range Sum Query Mutable at LeetCode

Originally posted at: @github.com/halfrost/LeetCode-Go