Problem show
User StewartStudios
Submission Time 2026-06-22 16:49:25
Score 0
Max Time N/A
Max Memory N/A

Compile Error

Alice.cpp: In function ‘std::vector<std::pair<int, int> > Alice()’:
Alice.cpp:10:49: error: ‘x’ was not declared in this scope
10 | for (int i = 2; i <= n; i++) result.push_back({x % (i - 1) + 1, i});
| ^
Alice.cpp:10:68: error: no matching function for call to ‘std::vector<std::pair<int, int> >::push_back(<brace-enclosed initializer list>)’
10 | for (int i = 2; i <= n; i++) result.push_back({x % (i - 1) + 1, i});
| ^
In file included from /usr/include/c++/9/vector:67,
from Alice.h:1,
from Alice.cpp:1:
/usr/include/c++/9/bits/stl_vector.h:1184:7: note: candidate: ‘void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = std::pair<int, int>; _Alloc = std::allocator<std::pair<int, int> >; std::vector<_Tp, _Alloc>