foo.cpp: In function 'int find(int)':
foo.cpp:16:7: error: reference to 'hash' is ambiguous
if (hash[M]<val)L=M+1;
^
foo.cpp:9:5: note: candidates are: int hash [20005]
int hash[MAXN],tot;
^
In file included from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\basic_string.h:3033:0,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\string:52,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\random:41,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\stl_algo.h:65,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\algorithm:62,
from foo.cpp:2:
c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\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:44:2: error: reference to 'hash' is ambiguous
hash[tot=1]=st[1];
^
foo.cpp:9:5: note: candidates are: int hash [20005]
int hash[MAXN],tot;
^
In file included from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\basic_string.h:3033:0,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\string:52,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\random:41,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\stl_algo.h:65,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\algorithm:62,
from foo.cpp:2:
c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\functional_hash.h:58:12: note: template<class _Tp> struct std::hash
struct hash;
^
foo.cpp:46:13: error: reference to 'hash' is ambiguous
if (st[i]!=hash[tot])
^
foo.cpp:9:5: note: candidates are: int hash [20005]
int hash[MAXN],tot;
^
In file included from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\basic_string.h:3033:0,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\string:52,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\random:41,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\stl_algo.h:65,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\algorithm:62,
from foo.cpp:2:
c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\functional_hash.h:58:12: note: template<class _Tp> struct std::hash
struct hash;
^
foo.cpp:47:2: error: reference to 'hash' is ambiguous
hash[++tot]=st[i];
^
foo.cpp:9:5: note: candidates are: int hash [20005]
int hash[MAXN],tot;
^
In file included from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\basic_string.h:3033:0,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\string:52,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\random:41,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\stl_algo.h:65,
from c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\algorithm:62,
from foo.cpp:2:
c:\tdm-gcc-32\lib\gcc\mingw32\4.8.1\include\c++\bits\functional_hash.h:58:12: note: template<class _Tp> struct std::hash
struct hash;
^