結果
問題 | No.129 お年玉(2) |
ユーザー | %20 |
提出日時 | 2017-01-02 12:59:48 |
言語 | C90 (gcc 12.3.0) |
結果 |
AC
|
実行時間 | 231 ms / 5,000 ms |
コード長 | 212 bytes |
コンパイル時間 | 340 ms |
コンパイル使用メモリ | 20,352 KB |
実行使用メモリ | 262,716 KB |
最終ジャッジ日時 | 2024-11-28 00:37:04 |
合計ジャッジ時間 | 6,404 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 23 ms
47,976 KB |
testcase_01 | AC | 231 ms
262,716 KB |
testcase_02 | AC | 1 ms
6,820 KB |
testcase_03 | AC | 1 ms
6,820 KB |
testcase_04 | AC | 1 ms
6,820 KB |
testcase_05 | AC | 85 ms
132,780 KB |
testcase_06 | AC | 136 ms
188,188 KB |
testcase_07 | AC | 174 ms
220,756 KB |
testcase_08 | AC | 131 ms
162,788 KB |
testcase_09 | AC | 151 ms
206,664 KB |
testcase_10 | AC | 166 ms
225,384 KB |
testcase_11 | AC | 96 ms
155,968 KB |
testcase_12 | AC | 129 ms
193,328 KB |
testcase_13 | AC | 133 ms
200,316 KB |
testcase_14 | AC | 127 ms
194,920 KB |
testcase_15 | AC | 101 ms
167,844 KB |
testcase_16 | AC | 117 ms
183,460 KB |
testcase_17 | AC | 147 ms
215,724 KB |
testcase_18 | AC | 138 ms
203,820 KB |
testcase_19 | AC | 148 ms
214,820 KB |
testcase_20 | AC | 146 ms
215,300 KB |
testcase_21 | AC | 208 ms
254,652 KB |
testcase_22 | AC | 103 ms
160,676 KB |
testcase_23 | AC | 154 ms
229,184 KB |
testcase_24 | AC | 137 ms
220,348 KB |
testcase_25 | AC | 94 ms
153,296 KB |
testcase_26 | AC | 97 ms
158,020 KB |
testcase_27 | AC | 97 ms
154,240 KB |
testcase_28 | AC | 181 ms
255,080 KB |
testcase_29 | AC | 1 ms
6,820 KB |
testcase_30 | AC | 1 ms
6,816 KB |
testcase_31 | AC | 1 ms
6,816 KB |
testcase_32 | AC | 1 ms
6,820 KB |
testcase_33 | AC | 8 ms
26,936 KB |
testcase_34 | AC | 4 ms
18,072 KB |
testcase_35 | AC | 6 ms
28,212 KB |
testcase_36 | AC | 8 ms
28,816 KB |
testcase_37 | AC | 8 ms
29,572 KB |
testcase_38 | AC | 34 ms
58,300 KB |
testcase_39 | AC | 45 ms
72,968 KB |
testcase_40 | AC | 92 ms
146,532 KB |
testcase_41 | AC | 66 ms
102,808 KB |
testcase_42 | AC | 37 ms
62,080 KB |
testcase_43 | AC | 36 ms
61,460 KB |
testcase_44 | AC | 176 ms
256,028 KB |
testcase_45 | AC | 25 ms
45,572 KB |
testcase_46 | AC | 48 ms
77,860 KB |
testcase_47 | AC | 174 ms
249,440 KB |
testcase_48 | AC | 102 ms
166,072 KB |
コンパイルメッセージ
main.c:1:1: warning: data definition has no type or storage class 1 | C[10001][10001]; | ^ main.c:1:1: warning: type defaults to ‘int’ in declaration of ‘C’ [-Wimplicit-int] main.c:3:1: warning: data definition has no type or storage class 3 | i,j,k; | ^ main.c:3:1: warning: type defaults to ‘int’ in declaration of ‘i’ [-Wimplicit-int] main.c:3:3: warning: type defaults to ‘int’ in declaration of ‘j’ [-Wimplicit-int] 3 | i,j,k; | ^ main.c:3:5: warning: type defaults to ‘int’ in declaration of ‘k’ [-Wimplicit-int] 3 | i,j,k; | ^ main.c:4:1: warning: return type defaults to ‘int’ [-Wimplicit-int] 4 | main(M){ | ^~~~ main.c: In function ‘main’: main.c:4:1: warning: type of ‘M’ defaults to ‘int’ [-Wimplicit-int] main.c:5:9: warning: implicit declaration of function ‘scanf’ [-Wimplicit-function-declaration] 5 | scanf("%lld%d",&N,&M); | ^~~~~ main.c:1:1: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’ +++ |+#include <stdio.h> 1 | C[10001][10001]; main.c:5:9: warning: incompatible implicit declaration of built-in function ‘scanf’ [-Wbuiltin-declaration-mismatch] 5 | scanf("%lld%d",&N,&M); | ^~~~~ main.c:5:9: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’ main.c:10:9: warning: implicit declaration of function ‘printf’ [-Wimplicit-function-declaration] 10 | printf("%d\n",C[M][k]); | ^~~~~~ main.c:10:9: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’ main.c:10:9: warning: incompatible implicit declaration of built-in function ‘printf’ [-Wbuiltin-declaration-mismatch] main.c:10:9: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’
ソースコード
C[10001][10001]; long long N; i,j,k; main(M){ scanf("%lld%d",&N,&M); k=N/1000%M; for(;i<=M;++i) for(C[i][0]=j=1;j<=i;++j) C[i][j]=(C[i-1][j-1]+C[i-1][j])%1000000000; printf("%d\n",C[M][k]); return 0; }