train.cpp: In function 'std::vector<int> who_wins(std::vector<int>, std::vector<int>, std::vector<int>, std::vector<int>)':
train.cpp:24:33: error: invalid types 'std::map<int, int>::mapped_type {aka int}[__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}]' for array subscript
24 | e[u[i]].pb(v[i]), M[u[i]][v[i]]=1;
| ^
train.cpp:31:20: error: invalid types 'std::map<int, int>::mapped_type {aka int}[__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}]' for array subscript
31 | if(M[v[i]][v[i]+1])
| ^