Problem singlefile
User bachnguyen123
Submission Time 2025-11-21 18:03:40
Score 0
Max Time N/A
Max Memory N/A

Compile Error

singlefile.cpp:5:17: error: expected identifier before numeric constant
5 | vector<int> f(100005, 0);
| ^~~~~~
singlefile.cpp:5:17: error: expected ‘,’ or ‘...’ before numeric constant
singlefile.cpp:21:2: error: expected ‘;’ after struct definition
21 | }
| ^
| ;
singlefile.cpp: In member function ‘void bit::upd(int, int)’:
singlefile.cpp:9:37: error: invalid types ‘<unresolved overloaded function type>[int]’ for array subscript
9 | for(; p <= n; p += (p & -p)) f[p] += v;
| ^
singlefile.cpp: In member function ‘int bit::qry(int)’:
singlefile.cpp:14:39: error: invalid types ‘<unresolved overloaded function type>[int]’ for array subscript
14 | for(; p; p -= (p & -p)) res += f[p];
| ^
singlefile.cpp: In function ‘int main()’:
singlefile.cpp:30:13: error: ‘class std::vector&