lampice.cpp: In function 'void dfs1(long long int, long long int)':
lampice.cpp:22:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < g[v].size(); i++)
~~^~~~~~~~~~~~~
lampice.cpp: In function 'void build(long long int, long long int)':
lampice.cpp:35:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < g[v].size(); i++)
~~^~~~~~~~~~~~~
lampice.cpp: In function 'long long int centroid(long long int, long long int, long long int)':
lampice.cpp:47:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < g[v].size(); i++)
~~^~~~~~~~~~~~~
lampice.cpp: In function 'void dfs2(long long int, long long int)':
lampice.cpp:86:13: error: no match for 'operator[]' (operand types are 'std::unordered_map<long long int, long long int>' and '<brace-enclosed initializer list>')
if(fl && mp[{ourhash, len - h[v]}] != 0)
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from /usr/include/c++/7/functional:60,
from /usr/include/x86_64-linux-gnu/c++/7/bits/stdc++.h:71,
from lampice.cpp:1:
/usr/include/c++/7/bits/unordered_map.h:975:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](const key_type&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](const key_type& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:975:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const key_type& {aka const long long int&}'
/usr/include/c++/7/bits/unordered_map.h:979:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type&&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](key_type&& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:979:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::unordered_map<long long int, long long int>::key_type&& {aka long long int&&}'
lampice.cpp:91:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < g[v].size(); i++)
~~^~~~~~~~~~~~~
lampice.cpp: In function 'void dfs3(long long int, long long int)':
lampice.cpp:139:5: error: no match for 'operator[]' (operand types are 'std::unordered_map<long long int, long long int>' and '<brace-enclosed initializer list>')
mp[{ourhash, h[v] + 1}]++;
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from /usr/include/c++/7/functional:60,
from /usr/include/x86_64-linux-gnu/c++/7/bits/stdc++.h:71,
from lampice.cpp:1:
/usr/include/c++/7/bits/unordered_map.h:975:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](const key_type&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](const key_type& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:975:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const key_type& {aka const long long int&}'
/usr/include/c++/7/bits/unordered_map.h:979:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type&&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](key_type&& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:979:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::unordered_map<long long int, long long int>::key_type&& {aka long long int&&}'
lampice.cpp:142:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < g[v].size(); i++)
~~^~~~~~~~~~~~~
lampice.cpp: In function 'void go_to(long long int)':
lampice.cpp:170:4: error: no match for 'operator[]' (operand types are 'std::unordered_map<long long int, long long int>' and '<brace-enclosed initializer list>')
mp[{s[v] - 'a' + 1, 1}] = 1;
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from /usr/include/c++/7/functional:60,
from /usr/include/x86_64-linux-gnu/c++/7/bits/stdc++.h:71,
from lampice.cpp:1:
/usr/include/c++/7/bits/unordered_map.h:975:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](const key_type&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](const key_type& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:975:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const key_type& {aka const long long int&}'
/usr/include/c++/7/bits/unordered_map.h:979:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type&&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](key_type&& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:979:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::unordered_map<long long int, long long int>::key_type&& {aka long long int&&}'
lampice.cpp:172:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i <g[v].size(); i++)
~~~^~~~~~~~~~~~
lampice.cpp:190:5: error: no match for 'operator[]' (operand types are 'std::unordered_map<long long int, long long int>' and 'std::pair<long long int, long long int>')
mp[v]--;
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from /usr/include/c++/7/functional:60,
from /usr/include/x86_64-linux-gnu/c++/7/bits/stdc++.h:71,
from lampice.cpp:1:
/usr/include/c++/7/bits/unordered_map.h:975:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](const key_type&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](const key_type& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:975:7: note: no known conversion for argument 1 from 'std::pair<long long int, long long int>' to 'const key_type& {aka const long long int&}'
/usr/include/c++/7/bits/unordered_map.h:979:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type& std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type&&) [with _Key = long long int; _Tp = long long int; _Hash = std::hash<long long int>; _Pred = std::equal_to<long long int>; _Alloc = std::allocator<std::pair<const long long int, long long int> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::mapped_type = long long int; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = long long int]
operator[](key_type&& __k)
^~~~~~~~
/usr/include/c++/7/bits/unordered_map.h:979:7: note: no known conversion for argument 1 from 'std::pair<long long int, long long int>' to 'std::unordered_map<long long int, long long int>::key_type&& {aka long long int&&}'
lampice.cpp:193:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < g[v].size(); i++)
~~^~~~~~~~~~~~~