Problem fenwicktree_easy
User wrizz69
Submission Time 2023-11-06 19:25:56
Score 0
Max Time N/A
Max Memory N/A

Compile Error

fenwicktree_easy.cpp: In function ‘int32_t main()’:
fenwicktree_easy.cpp:38:32: error: invalid conversion from ‘std::ios_base& (*)(std::ios_base&)’ to ‘std::vector<long long int>::size_type’ {aka ‘long unsigned int’} [-fpermissive]
38 | cout << prefix_sum[right] - prefix_sum[left - 1] << std::endl;
| ^~~~~
| |
| std::ios_base& (*)(std::ios_base&)
In file included from /usr/include/c++/9/vector:67,
from /usr/include/c++/9/functional:62,
from /usr/include/c++/9/pstl/glue_algorithm_defs.h:13,
from /usr/include/c++/9/algorithm:71,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from fenwicktree_easy.cpp:1:
/usr/include/c++/9/bits/stl_vector.h:1040:28: note: initializing argument 1 of ‘std::vector<_Tp, _Alloc>::