Problem gotoschool
User jiazethesigma
Submission Time 2025-12-07 15:08:18
Score 0
Max Time N/A
Max Memory N/A

Compile Error

gotoschool.cpp: In function ‘int main()’:
gotoschool.cpp:14:12: error: no match for ‘operator[]’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<std::pair<int, int> >, std::pair<int, int> >::value_type’ {aka ‘std::pair<int, int>’} and ‘int’)
14 | cin>>a[i][0];
| ^
gotoschool.cpp:15:7: error: no match for ‘operator[]’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<std::pair<int, int> >, std::pair<int, int> >::value_type’ {aka ‘std::pair<int, int>’} and ‘int’)
15 | a[i][1]=i;
| ^
gotoschool.cpp:20:13: error: no match for ‘operator[]’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<std::pair<int, int> >, std::pair<int, int> >::value_type’ {aka ‘std::pair<int, int>’} and ‘int’)
20 | cout<<a[i][1];
| ^