记录详情

Accepted

foo.cc: In function 'int main()':
foo.cc:6:13: warning: 'char* gets(char*)' is deprecated [-Wdeprecated-declarations]
    6 |         gets(s);
      |         ~~~~^~~
In file included from /nix/store/hf2gy3km07d5m0p1lwmja0rg9wlnmyr7-gcc-12.3.0/include/c++/12.3.0/cstdio:42,
                 from stdc++.h:46:
/nix/store/mrgib0s2ayr81xv1q84xsjg8ijybalq3-glibc-2.38-27-dev/include/stdio.h:663:14: note: declared here
  663 | extern char *gets (char *__s) __wur __attribute_deprecated__;
      |              ^~~~
foo.cc:7:23: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
    7 |         for (int i=0;i<strlen(s);i++){
      |                      ~^~~~~~~~~~
foo.cc:11:22: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
   11 |                 if (i==strlen(s)-1) s[i]=' ';
      |                     ~^~~~~~~~~~~~~
foo.cc:13:23: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
   13 |         for (int i=0;i<strlen(s);i++)
      |                      ~^~~~~~~~~~
foo.cc:5:24: warning: unused variable 'c' [-Wunused-variable]
    5 |         char s[100010],c,minm=10,mini;
      |                        ^
foo.cc:5:26: warning: unused variable 'minm' [-Wunused-variable]
    5 |         char s[100010],c,minm=10,mini;
      |                          ^~~~
foo.cc:5:34: warning: unused variable 'mini' [-Wunused-variable]
    5 |         char s[100010],c,minm=10,mini;
      |                                  ^~~~
/nix/store/1fn92b0783crypjcxvdv6ycmvi27by0j-binutils-2.40/bin/ld: /tmp/ccEkzA4v.o: in function `main':
foo.cc:(.text.startup+0x10): warning: the `gets' function is dangerous and should not be used.
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Accepted 4ms 412.0 KiB
#2 Accepted 4ms 332.0 KiB
#3 Accepted 4ms 516.0 KiB
#4 Accepted 3ms 412.0 KiB
#5 Accepted 4ms 412.0 KiB

信息

递交者
类型
递交
题目
5-8 留下最大数
语言
C++
递交时间
2023-12-21 20:37:34
评测时间
2023-12-21 20:37:34
评测机
分数
100
总耗时
20ms
峰值内存
516.0 KiB