Im having a problem which need a structure that can handle 2 operations:
Change values of nodes from position x to position y to newValue.
Get the sum of values from position a to b.
The number of nodes is 50000 and number of queries is 50000. Im trying to implement IT tree with lazy update but i can't figure out how. The first operation is somehow different from the usual add and multiply operation.