0_0_32368198_12766.cpp:8:22: error: 'int nan [505]' redeclared as different kind of symbol
int used[505],nan[505];
^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/cmath:44:0,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/random:38,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algo.h:66,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:62,
from 0_0_32368198_12766.cpp:4:
GCC4.9.2/x86_64-w64-mingw32/include/math.h:931:25: note: previous declaration 'double nan(const char*)'
extern double __cdecl nan(const char *tagp);
^
0_0_32368198_12766.cpp: In function 'int find(int)':
0_0_32368198_12766.cpp:13:28: error: invalid conversion from 'double (*)(const char*)' to 'int' [-fpermissive]
if(nan[i]==0||find(nan[i])){
^
0_0_32368198_12766.cpp:9:5: note: initializing argument 1 of 'int find(int)'
int find(int x){
^
0_0_32368198_12766.cpp:14:12: error: assignment of read-only location '*(nan + ((sizetype)i))'
nan[i]=x;
^
0_0_32368198_12766.cpp:14:12: error: cannot convert 'int' to 'double(const char*)' in assignment
0_0_32368198_12766.cpp: In function 'int main()':
0_0_32368198_12766.cpp:31:34: error: invalid conversion from 'double (*)(const char*)' to 'void*' [-fpermissive]
memset(nan,0,(m+1)*sizeof(int));
^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/cstring:42:0,
from 0_0_32368198_12766.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/string.h:43:18: note: initializing argument 1 of 'void* memset(void*, int, size_t)'
void * __cdecl memset(void *_Dst,int _Val,size_t _Size);
^
0_0_32368198_12766.cpp:33:8: error: 'i' was not declared in this scope
for(i=1;i<=n;i++){
^
|