Borderou de evaluare (job #1314135)

Utilizator serban_ioan97Ciofu Serban serban_ioan97 Data 11 ianuarie 2015 16:15:21
Problema Secventa 5 Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp: In function ‘int find_value(unsigned int)’: user.cpp:24:13: error: reference to ‘hash’ is ambiguous int len=hash[list].size(); ^ user.cpp:13:14: note: candidates are: std::vector<int> hash [9319] vector <int> hash[mod] ; ^ In file included from /usr/include/c++/4.8/bits/basic_string.h:3033:0, from /usr/include/c++/4.8/string:52, from /usr/include/c++/4.8/random:41, from /usr/include/c++/4.8/bits/stl_algo.h:65, from /usr/include/c++/4.8/algorithm:62, from user.cpp:3: /usr/include/c++/4.8/bits/functional_hash.h:58:12: note: template<class _Tp> struct std::hash struct hash; ^ user.cpp:27:8: error: reference to ‘hash’ is ambiguous if(hash[list][i]==x) return place[list][i]; ^ user.cpp:13:14: note: candidates are: std::vector<int> hash [9319] vector <int> hash[mod] ; ^ In file included from /usr/include/c++/4.8/bits/basic_string.h:3033:0, from /usr/include/c++/4.8/string:52, from /usr/include/c++/4.8/random:41, from /usr/include/c++/4.8/bits/stl_algo.h:65, from /usr/include/c++/4.8/algorithm:62, from user.cpp:3: /usr/include/c++/4.8/bits/functional_hash.h:58:12: note: template<class _Tp> struct std::hash struct hash; ^ user.cpp: In function ‘void insert_value(unsigned int, int)’: user.cpp:40:9: error: reference to ‘hash’ is ambiguous hash[list].push_back(x); ^ user.cpp:13:14: note: candidates are: std::vector<int> hash [9319] vector <int> hash[mod] ; ^ In file included from /usr/include/c++/4.8/bits/basic_string.h:3033:0, from /usr/include/c++/4.8/string:52, from /usr/include/c++/4.8/random:41, from /usr/include/c++/4.8/bits/stl_algo.h:65, from /usr/include/c++/4.8/algorithm:62, from user.cpp:3: /usr/include/c++/4.8/bits/functional_hash.h:58:12: note: template<class _Tp> struct std::hash struct hash; ^ user.cpp: In function ‘int main()’: user.cpp:79:37: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("secv5.in", "rt", stdin);

Ceva nu functioneaza?