Problem candies
User hackerman123
Submission Time 2023-03-16 23:09:54
Score 0
Max Time N/A
Max Memory N/A

Compile Error

candies.cpp: In function ‘void update(int, int, int)’:
candies.cpp:17:3: error: ‘fenwick’ was not declared in this scope; did you mean ‘fenwicktree’?
17 | fenwick[where] += value;
| ^~~~~~~
| fenwicktree
candies.cpp: In function ‘bool check(int)’:
candies.cpp:23:29: error: expected ‘;’ before ‘}’ token
23 | return(fenwicktree[i] == i)
| ^
| ;
24 | }
| ~
candies.cpp: In function ‘int main()’:
candies.cpp:28:25: error: expected ‘;’ before ‘fenwicktree’
28 | v.resize(1000000000, 0)
| ^
| ;
29 | fenwicktree.resize(1000000000, 0)
| ~~~~~~~~~~~
candies.cpp:30:20: error: ‘i’ was not declared in this scope
30 | for (long long i; i < n; i++){
| ^
candies.cpp: At global scope:
candi