QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#364849#8057. Best Carry Player 4ZhaoZiLongCompile Error//C++111.5kb2024-03-24 16:58:032024-03-24 16:58:04

詳細信息

answer.code:7:1: warning: ISO C++ forbids declaration of ‘main’ with no type [-Wreturn-type]
    7 | main(){
      | ^~~~
answer.code: In function ‘int main()’:
answer.code:39:43: error: expected primary-expression before ‘]’ token
   39 |                                 ans+=a[i];]
      |                                           ^
answer.code:14:30: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   14 |                         scanf("%lld",&a[i]);
      |                         ~~~~~^~~~~~~~~~~~~~
answer.code:18:30: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   18 |                         scanf("%lld",&b[i]);
      |                         ~~~~~^~~~~~~~~~~~~~