zagrade.cpp: In function 'void Chain(const string&)':
zagrade.cpp:16:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (int i = 0; i < pref.size(); ++i)
~~^~~~~~~~~~~~~
zagrade.cpp: In function 'void Dfs(int, int)':
zagrade.cpp:32:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (int i = 0; i < nei[v].size(); ++i)
~~^~~~~~~~~~~~~~~
zagrade.cpp: In function 'int main()':
zagrade.cpp:67:7: error: invalid operands of types 'long long int' and 'void' to binary 'operator+'
ans += Chain(a);
~~~~^~~~~~~~~~~
zagrade.cpp:67:17: error: in evaluation of 'operator+=(long long int, void)'
ans += Chain(a);
^
zagrade.cpp:68:3: error: 'reverse' was not declared in this scope
reverse(a.begin(), a.end());
^~~~~~~
zagrade.cpp:69:7: error: invalid operands of types 'long long int' and 'void' to binary 'operator+'
ans += Chain(a);
~~~~^~~~~~~~~~~
zagrade.cpp:69:17: error: in evaluation of 'operator+=(long long int, void)'
ans += Chain(a);
^