結果
問題 | No.482 あなたの名は |
ユーザー | kotatsugame |
提出日時 | 2017-02-13 02:30:33 |
言語 | C90 (gcc 11.4.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 158 bytes |
コンパイル時間 | 138 ms |
コンパイル使用メモリ | 19,712 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-06-09 10:11:59 |
合計ジャッジ時間 | 1,703 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | WA | - |
testcase_01 | WA | - |
testcase_02 | AC | 0 ms
6,940 KB |
testcase_03 | AC | 1 ms
6,940 KB |
testcase_04 | WA | - |
testcase_05 | AC | 1 ms
6,940 KB |
testcase_06 | WA | - |
testcase_07 | AC | 1 ms
6,940 KB |
testcase_08 | AC | 1 ms
6,944 KB |
testcase_09 | AC | 1 ms
6,940 KB |
testcase_10 | AC | 1 ms
6,940 KB |
testcase_11 | WA | - |
testcase_12 | AC | 1 ms
6,944 KB |
testcase_13 | WA | - |
testcase_14 | WA | - |
testcase_15 | WA | - |
testcase_16 | AC | 28 ms
6,940 KB |
testcase_17 | AC | 29 ms
6,940 KB |
testcase_18 | AC | 28 ms
6,940 KB |
testcase_19 | WA | - |
testcase_20 | AC | 28 ms
6,944 KB |
testcase_21 | WA | - |
testcase_22 | WA | - |
testcase_23 | WA | - |
testcase_24 | WA | - |
testcase_25 | WA | - |
testcase_26 | AC | 29 ms
6,940 KB |
testcase_27 | AC | 29 ms
6,944 KB |
testcase_28 | WA | - |
testcase_29 | AC | 25 ms
6,944 KB |
testcase_30 | AC | 0 ms
6,940 KB |
コンパイルメッセージ
main.c:1:8: warning: data definition has no type or storage class 1 | long k;c,n,d[1<<18],u[1<<18];main(i){for(scanf("%d%ld",&n,&k);~scanf("%d",d+i++););for(i--;--i;c--)for(;!u[i];i=d[i])u[i]=++c;n=!puts(k<c||k-c&1?"NO":"YES");} | ^ main.c:1:8: warning: type defaults to ‘int’ in declaration of ‘c’ [-Wimplicit-int] main.c:1:10: warning: type defaults to ‘int’ in declaration of ‘n’ [-Wimplicit-int] 1 | long k;c,n,d[1<<18],u[1<<18];main(i){for(scanf("%d%ld",&n,&k);~scanf("%d",d+i++););for(i--;--i;c--)for(;!u[i];i=d[i])u[i]=++c;n=!puts(k<c||k-c&1?"NO":"YES");} | ^ main.c:1:12: warning: type defaults to ‘int’ in declaration of ‘d’ [-Wimplicit-int] 1 | long k;c,n,d[1<<18],u[1<<18];main(i){for(scanf("%d%ld",&n,&k);~scanf("%d",d+i++););for(i--;--i;c--)for(;!u[i];i=d[i])u[i]=++c;n=!puts(k<c||k-c&1?"NO":"YES");} | ^ main.c:1:21: warning: type defaults to ‘int’ in declaration of ‘u’ [-Wimplicit-int] 1 | long k;c,n,d[1<<18],u[1<<18];main(i){for(scanf("%d%ld",&n,&k);~scanf("%d",d+i++););for(i--;--i;c--)for(;!u[i];i=d[i])u[i]=++c;n=!puts(k<c||k-c&1?"NO":"YES");} | ^ main.c:1:30: warning: return type defaults to ‘int’ [-Wimplicit-int] 1 | long k;c,n,d[1<<18],u[1<<18];main(i){for(scanf("%d%ld",&n,&k);~scanf("%d",d+i++););for(i--;--i;c--)for(;!u[i];i=d[i])u[i]=++c;n=!puts(k<c||k-c&1?"NO":"YES");} | ^~~~ main.c: In function ‘main’: main.c:1:30: warning: type of ‘i’ defaults to ‘int’ [-Wimplicit-int] main.c:1:42: warning: implicit declaration of function ‘scanf’ [-Wimplicit-function-declaration] 1 | long k;c,n,d[1<<18],u[1<<18];main(i){for(scanf("%d%ld",&n,&k);~scanf("%d",d+i++););for(i--;--i;c--)for(;!u[i];i=d[i])u[i]=++c;n=!puts(k<c||k-c&1?"NO":"YES");} | ^~~~~ main.c:1:1: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’ +++ |+#include
ソースコード
long k;c,n,d[1<<18],u[1<<18];main(i){for(scanf("%d%ld",&n,&k);~scanf("%d",d+i++););for(i--;--i;c--)for(;!u[i];i=d[i])u[i]=++c;n=!puts(k<c||k-c&1?"NO":"YES");}