Pagini recente » Borderou de evaluare (job #797442) | Borderou de evaluare (job #448309) | Borderou de evaluare (job #153250) | Borderou de evaluare (job #405349) | Borderou de evaluare (job #383305)
Borderou de evaluare (job #383305)
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘int find(unsigned int)’:
user.cpp:16:22: error: reference to ‘hash’ is ambiguous
int key=x%MOD,sz=hash[key].size(),i;
^
user.cpp:12:34: note: candidates are: std::vector<std::pair<unsigned int, int> > hash [666013]
vector< pair<unsigned int,int> > hash[MOD];
^
In file included from /usr/include/c++/4.8/bits/stl_bvector.h:1134:0,
from /usr/include/c++/4.8/vector:65,
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:17:10: error: ‘i’ was not declared in this scope
for (i=0;i<sz;i++)
^
user.cpp:18:13: error: reference to ‘hash’ is ambiguous
if (hash[key][i].first==x)
^
user.cpp:12:34: note: candidates are: std::vector<std::pair<unsigned int, int> > hash [666013]
vector< pair<unsigned int,int> > hash[MOD];
^
In file included from /usr/include/c++/4.8/bits/stl_bvector.h:1134:0,
from /usr/include/c++/4.8/vector:65,
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:19:20: error: reference to ‘hash’ is ambiguous
return hash[key][i].second;
^
user.cpp:12:34: note: candidates are: std::vector<std::pair<unsigned int, int> > hash [666013]
vector< pair<unsigned int,int> > hash[MOD];
^
In file included from /usr/include/c++/4.8/bits/stl_bvector.h:1134:0,
from /usr/include/c++/4.8/vector:65,
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 add(unsigned int, int)’:
user.cpp:28:9: error: reference to ‘hash’ is ambiguous
hash[x%MOD].push_back(make_pair(x,indx));
^
user.cpp:12:34: note: candidates are: std::vector<std::pair<unsigned int, int> > hash [666013]
vector< pair<unsigned int,int> > hash[MOD];
^
In file included from /usr/include/c++/4.8/bits/stl_bvector.h:1134:0,
from /usr/include/c++/4.8/vector:65,
from user.cpp:3:
Test |
Timp executie |
Memorie folosita |
Mesaj |
Punctaj/test |
1 | 28ms | 8016kb | OK | 10 |
2 | 24ms | 8040kb | OK | 10 |
3 | 36ms | 8164kb | OK | 10 |
4 | 96ms | 8812kb | OK | 10 |
5 | 120ms | 8596kb | OK | 10 |
6 | 312ms | 11188kb | OK | 10 |
7 | 736ms | 12940kb | OK | 10 |
8 | 856ms | 13032kb | OK | 10 |
9 | 1448ms | 19600kb | OK | 10 |
10 | 1352ms | 26012kb | OK | 10 |
Punctaj total | 0 |