/ Vijos /

记录详情

Runtime Error

/in/foo.c: In function 'main':
/in/foo.c:6:17: warning: format '%d' expects argument of type 'int *', but argument 2 has type 'long int *' [-Wformat=]
    6 |         scanf("%d %d %d %d",&l,&s,&t,&m);
      |                ~^           ~~
      |                 |           |
      |                 int *       long int *
      |                %ld
/in/foo.c:6:20: warning: format '%d' expects argument of type 'int *', but argument 3 has type 'long int *' [-Wformat=]
    6 |         scanf("%d %d %d %d",&l,&s,&t,&m);
      |                   ~^           ~~
      |                    |           |
      |                    int *       long int *
      |                   %ld
/in/foo.c:6:23: warning: format '%d' expects argument of type 'int *', but argument 4 has type 'long int *' [-Wformat=]
    6 |         scanf("%d %d %d %d",&l,&s,&t,&m);
      |                      ~^           ~~
      |                       |           |
      |                       int *       long int *
      |                      %ld
/in/foo.c:6:26: warning: format '%d' expects argument of type 'int *', but argument 5 has type 'long int *' [-Wformat=]
    6 |         scanf("%d %d %d %d",&l,&s,&t,&m);
      |                         ~^           ~~
      |                          |           |
      |                          int *       long int *
      |                         %ld
/in/foo.c:8:41: warning: format '%d' expects argument of type 'int *', but argument 2 has type 'long int *' [-Wformat=]
    8 |         for (i = 0; i < m; i++) scanf("%d",&a[i]);
      |                                        ~^  ~~~~~
      |                                         |  |
      |                                         |  long int *
      |                                         int *
      |                                        %ld
/in/foo.c:16:26: warning: format '%d' expects argument of type 'int', but argument 2 has type 'long int' [-Wformat=]
   16 |                 printf("%d", ans);
      |                         ~^   ~~~
      |                          |   |
      |                          int long int
      |                         %ld
/in/foo.c:63:18: warning: format '%d' expects argument of type 'int', but argument 2 has type 'long int' [-Wformat=]
   63 |         printf("%d", ans);
      |                 ~^   ~~~
      |                  |   |
      |                  int long int
      |                 %ld
# 状态 耗时 内存占用
#1 Runtime Error 1ms 284.0 KiB
#2 Runtime Error 1ms 428.0 KiB
#3 Wrong Answer 1ms 284.0 KiB
#4 Runtime Error 1ms 452.0 KiB
#5 Runtime Error 1ms 444.0 KiB
#6 Runtime Error 1ms 336.0 KiB
#7 Wrong Answer 1ms 284.0 KiB
#8 Runtime Error 1ms 448.0 KiB
#9 Runtime Error 1ms 444.0 KiB
#10 Wrong Answer 1ms 284.0 KiB

信息

递交者
类型
递交
题目
P1002 过河
语言
C
递交时间
2025-12-19 18:25:50
评测时间
2025-12-19 18:25:50
评测机
分数
0
总耗时
14ms
峰值内存
452.0 KiB