记录详情

Wrong Answer

/in/foo.cc: In function 'int main()':
/in/foo.cc:12:17: warning: 'char* gets(char*)' is deprecated [-Wdeprecated-declarations]
  char s[100001];gets(s);
                 ^~~~
In file included from /in/foo.cc:1:0:
/usr/include/stdio.h:640:14: note: declared here
 extern char *gets (char *__s) __wur __attribute_deprecated__;
              ^~~~
/in/foo.cc:12:23: warning: 'char* gets(char*)' is deprecated [-Wdeprecated-declarations]
  char s[100001];gets(s);
                       ^
In file included from /in/foo.cc:1:0:
/usr/include/stdio.h:640:14: note: declared here
 extern char *gets (char *__s) __wur __attribute_deprecated__;
              ^~~~
/in/foo.cc:17:10: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  while (i<strlen(s))
         ~^~~~~~~~~~
/in/foo.cc:19:7: warning: variable 'flag' set but not used [-Wunused-but-set-variable]
   int flag=1;
       ^~~~
/in/foo.cc:15:6: warning: unused variable 'namelen' [-Wunused-variable]
  int namelen=strlen(name);
      ^~~~~~~
/tmp/ccPynBwn.o: In function `main':
foo.cc:(.text.startup+0x2f): warning: the `gets' function is dangerous and should not be used.
# 状态 耗时 内存占用
#1 Accepted 1ms 364.0 KiB
#2 Accepted 1ms 340.0 KiB
#3 Accepted 1ms 356.0 KiB
#4 Wrong Answer 1ms 340.0 KiB
#5 Wrong Answer 1ms 376.0 KiB

信息

递交者
类型
递交
题目
P2968 4-3 爱情故事
语言
C++
递交时间
2023-12-05 16:44:57
评测时间
2023-12-05 16:44:57
评测机
分数
60
总耗时
8ms
峰值内存
376.0 KiB