/ TYWZ /

记录详情

Compile Error

/in/foo.cc:3:34: error: 'int index [103]' redeclared as different kind of symbol
 int head[103],cnt,n,m,q,index[103],s,c,d,dist,ans;
                                  ^
In file included from /usr/include/c++/6/cstring:42:0,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:48,
                 from /in/foo.cc:1:
/usr/include/string.h:477:1: note: previous declaration 'const char* index(const char*, int)'
 index (const char *__s, int __c) __THROW
 ^~~~~
/in/foo.cc: In function 'void bfs()':
/in/foo.cc:25:13: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
   if(index[s]>c&&ans)
             ^
/in/foo.cc: In function 'int main()':
/in/foo.cc:41:19: error: invalid operands of types '<unresolved overloaded function type>' and 'int' to binary 'operator+'
   scanf("%d",index+i);
              ~~~~~^~

信息

递交者
类型
递交
比赛
2019年6月15日高一(第二学期)模拟测试(九)
语言
C++
递交时间
2019-06-15 11:54:37
评测时间
2019-06-15 11:54:37
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes