QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#838036#9925. LR Stringza11Compile Error//C++1799b2024-12-30 18:37:532024-12-30 18:37:53

Judging History

你现在查看的是最新测评结果

  • [2024-12-30 18:37:53]
  • 评测
  • [2024-12-30 18:37:53]
  • 提交

answer

#include <bits/stdc++.h>
using namespace std;


int index[20];
int main ()
{
    cout<<1;
}

详细

answer.code:5:13: error: ‘int index [20]’ redeclared as different kind of entity
    5 | int index[20];
      |             ^
In file included from /usr/include/string.h:432,
                 from /usr/include/c++/13/cstring:42,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:121,
                 from answer.code:1:
/usr/include/strings.h:61:1: note: previous declaration ‘const char* index(const char*, int)’
   61 | index (const char *__s, int __c) __THROW
      | ^~~~~