Problem | prefixsums |
---|---|
User | blob |
Submission Time | 2023-11-17 13:21:54 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
prefixsums.cpp: In function ‘int main()’:
prefixsums.cpp:7:3: error: expected initializer before ‘pre’
7 | pre[0]=0;
| ^~~
prefixsums.cpp:10:3: error: ‘pre’ was not declared in this scope
10 | pre[i]=pre[i-1]+arr[i];
| ^~~
prefixsums.cpp:14:16: error: expected ‘;’ before ‘cout’
14 | cin >> l >> r
| ^
| ;
15 | cout << pre[r] - pre[i-1] <<' ';
| ~~~~