class NumArray {
public:
vector<int> n;
NumArray(vector<int>& nums) {
int res = 0;
// n.resize(nums.size());
n.push_back(res);
for(int i = 0; i<nums.size() ;i++){
// nums[i] += nums[i-1];
res += nums[i];
cout<<res<<endl;
n.push_back(res);
}
}
int sumRange(int i, int j) {
cout<<n[j+1] <<" "<<n[i]<<endl;
return n[j+1] - n[i];
}
};