Range Sum Query - Immutable

Imagine you are a financial analyst tasked with calculating the total revenue of a company over a specific period. The company's revenue is represented by an array of integers, where each integer corresponds to the revenue on a particular day. Your goal is to design a system that can efficiently handle multiple queries about the total revenue between any two given days. To achieve this, you will implement a class called Solution that takes the revenue array as input and provides a method to calculate the total revenue between any two days.

Examples
Input: [["Solution","sumRange","sumRange","sumRange"],[[[-2,0,3,-5,2,-1]],[0,2],[2,5],[0,5]]]
Output: [null,1,-1,-3]
Hints

Range Sum Query - Immutable

Imagine you are a financial analyst tasked with calculating the total revenue of a company over a specific period. The company's revenue is represented by an array of integers, where each integer corresponds to the revenue on a particular day. Your goal is to design a system that can efficiently handle multiple queries about the total revenue between any two given days. To achieve this, you will implement a class called `Solution` that takes the revenue array as input and provides a method to calculate the total revenue between any two days.