/ Vijos /

记录详情

Compile Error

foo.cpp: In function 'void dfs_cir(int, int)':
foo.cpp:63:9: error: reference to 'hash' is ambiguous
     if (hash[x]) return;
         ^
foo.cpp:41:16: note: candidates are: int hash [100010]
 int cir[N],tot,hash[N];
                ^
In file included from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/stl_bvector.h:1181:0,
                 from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/vector:65,
                 from foo.cpp:11:
C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/functional_hash.h:58:12: note:                 template<class _Tp> struct std::hash
     struct hash;
            ^
foo.cpp:65:5: error: reference to 'hash' is ambiguous
     hash[x]=tot;
     ^
foo.cpp:41:16: note: candidates are: int hash [100010]
 int cir[N],tot,hash[N];
                ^
In file included from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/stl_bvector.h:1181:0,
                 from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/vector:65,
                 from foo.cpp:11:
C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/functional_hash.h:58:12: note:                 template<class _Tp> struct std::hash
     struct hash;
            ^
foo.cpp:74:13: error: reference to 'hash' is ambiguous
         len[hash[x]][hash[to[i]]]=len[hash[to[i]]][hash[x]]=l[i];
             ^
foo.cpp:41:16: note: candidates are: int hash [100010]
 int cir[N],tot,hash[N];
                ^
In file included from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/stl_bvector.h:1181:0,
                 from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/vector:65,
                 from foo.cpp:11:
C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/functional_hash.h:58:12: note:                 template<class _Tp> struct std::hash
     struct hash;
            ^
foo.cpp:74:22: error: reference to 'hash' is ambiguous
         len[hash[x]][hash[to[i]]]=len[hash[to[i]]][hash[x]]=l[i];
                      ^
foo.cpp:41:16: note: candidates are: int hash [100010]
 int cir[N],tot,hash[N];
                ^
In file included from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/stl_bvector.h:1181:0,
                 from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/vector:65,
                 from foo.cpp:11:
C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/functional_hash.h:58:12: note:                 template<class _Tp> struct std::hash
     struct hash;
            ^
foo.cpp:74:39: error: reference to 'hash' is ambiguous
         len[hash[x]][hash[to[i]]]=len[hash[to[i]]][hash[x]]=l[i];
                                       ^
foo.cpp:41:16: note: candidates are: int hash [100010]
 int cir[N],tot,hash[N];
                ^
In file included from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/stl_bvector.h:1181:0,
                 from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/vector:65,
                 from foo.cpp:11:
C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/functional_hash.h:58:12: note:                 template<class _Tp> struct std::hash
     struct hash;
            ^
foo.cpp:74:52: error: reference to 'hash' is ambiguous
         len[hash[x]][hash[to[i]]]=len[hash[to[i]]][hash[x]]=l[i];
                                                    ^
foo.cpp:41:16: note: candidates are: int hash [100010]
 int cir[N],tot,hash[N];
                ^
In file included from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/stl_bvector.h:1181:0,
                 from C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/vector:65,
                 from foo.cpp:11:
C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/bits/functional_hash.h:58:12: note:                 template<class _Tp> struct std::hash
     struct hash;
            ^
foo.cpp: In function 'int main()':
foo.cpp:122:35: error: reference to 'hash' is ambiguous
                     up[x]+=k*(len[hash[pre[j]]][hash[j]]+down[j]*son[j]/(son[j]+1));
                                   ^
foo.cpp:41:16: note: candidates are: int hash [100010]
 int cir[N],tot,hash[N];

信息

递交者
类型
递交
题目
P1807 迷失游乐园
语言
C++
递交时间
2015-07-09 15:23:48
评测时间
2015-07-09 15:24:14
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes