結果

問題 No.446 ゆきこーだーの雨と雪 (1)
コンテスト
ユーザー testestest
提出日時 2016-12-04 07:13:36
言語 C90
(gcc 15.2.0)
コンパイル:
gcc-15 -O2 -std=c90 -DONLINE_JUDGE -o a.out _filename_ -lm
実行:
./a.out
結果
WA  
(最新)
AC  
(最初)
実行時間 -
コード長 103 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 154 ms
コンパイル使用メモリ 35,284 KB
最終ジャッジ日時 2026-02-23 23:13:53
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3 WA * 1
other AC * 10 WA * 3
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.c:1:1: warning: data definition has no type or storage class
    1 | n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?12346:!puts(f-3?"NG":"OK")););}
      | ^
main.c:1:3: warning: data definition has no type or storage class
    1 | n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?12346:!puts(f-3?"NG":"OK")););}
      |   ^
main.c: In function 'main':
main.c:1:22: warning: incompatible implicit declaration of built-in function 'sprintf' [-Wbuiltin-declaration-mismatch]
    1 | n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?12346:!puts(f-3?"NG":"OK")););}
      |                      ^~~~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'sprintf'
  +++ |+#include <stdio.h>
    1 | n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?12346:!puts(f-3?"NG":"OK")););}
main.c:1:30: warning: passing argument 1 of 'sprintf' from incompatible pointer type [-Wincompatible-pointer-types]
    1 | n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?12346:!puts(f-3?"NG":"OK")););}
      |                              ^~
      |                              |
      |                              int *
main.c:1:30: note: expected 'char *' but argument is of type 'int *'
main.c:1:54: warning: passing argument 1 of 'strcmp' from incompatible pointer type [-Wincompatible-pointer-types]
    1 | n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?12346:!puts(f-3?"NG":"OK")););}
      |                                                      ^~
      |                                                      |
      |                                                      int *
main.c:1:54: note: expected 'const char *' but argument is of type 'int *'
main.c:1:57: warning: passing argument 2 of 'strcmp' from incompatible pointer type [-Wincompatible-pointer-types]
    1 | n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?

ソースコード

diff #
raw source code

n;s;main(f,t){for(;n?sprintf(&t,"%d",--n),f+=!strcmp(&s,&t):(n=gets(&s)?12346:!puts(f-3?"NG":"OK")););}
0