結果
問題 | No.129 お年玉(2) |
ユーザー | %20 |
提出日時 | 2017-01-02 12:59:48 |
言語 | C90 (gcc 11.4.0) |
結果 |
AC
|
実行時間 | 204 ms / 5,000 ms |
コード長 | 212 bytes |
コンパイル時間 | 594 ms |
コンパイル使用メモリ | 20,480 KB |
実行使用メモリ | 234,752 KB |
最終ジャッジ日時 | 2024-05-05 23:11:13 |
合計ジャッジ時間 | 6,341 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 14 ms
19,968 KB |
testcase_01 | AC | 204 ms
234,752 KB |
testcase_02 | AC | 1 ms
5,376 KB |
testcase_03 | AC | 1 ms
5,376 KB |
testcase_04 | AC | 0 ms
5,376 KB |
testcase_05 | AC | 92 ms
106,624 KB |
testcase_06 | AC | 140 ms
160,256 KB |
testcase_07 | AC | 163 ms
192,768 KB |
testcase_08 | AC | 118 ms
136,576 KB |
testcase_09 | AC | 154 ms
178,688 KB |
testcase_10 | AC | 171 ms
199,168 KB |
testcase_11 | AC | 113 ms
131,328 KB |
testcase_12 | AC | 141 ms
167,168 KB |
testcase_13 | AC | 146 ms
174,080 KB |
testcase_14 | AC | 142 ms
168,576 KB |
testcase_15 | AC | 121 ms
141,440 KB |
testcase_16 | AC | 135 ms
158,848 KB |
testcase_17 | AC | 168 ms
189,312 KB |
testcase_18 | AC | 155 ms
179,456 KB |
testcase_19 | AC | 164 ms
190,336 KB |
testcase_20 | AC | 168 ms
188,928 KB |
testcase_21 | AC | 200 ms
230,272 KB |
testcase_22 | AC | 115 ms
137,856 KB |
testcase_23 | AC | 174 ms
204,544 KB |
testcase_24 | AC | 168 ms
197,248 KB |
testcase_25 | AC | 111 ms
132,224 KB |
testcase_26 | AC | 115 ms
135,040 KB |
testcase_27 | AC | 114 ms
131,328 KB |
testcase_28 | AC | 202 ms
232,064 KB |
testcase_29 | AC | 1 ms
5,376 KB |
testcase_30 | AC | 0 ms
5,376 KB |
testcase_31 | AC | 1 ms
5,376 KB |
testcase_32 | AC | 1 ms
5,376 KB |
testcase_33 | AC | 3 ms
5,632 KB |
testcase_34 | AC | 2 ms
5,376 KB |
testcase_35 | AC | 3 ms
5,376 KB |
testcase_36 | AC | 3 ms
5,760 KB |
testcase_37 | AC | 4 ms
6,656 KB |
testcase_38 | AC | 27 ms
35,200 KB |
testcase_39 | AC | 42 ms
50,176 KB |
testcase_40 | AC | 104 ms
123,776 KB |
testcase_41 | AC | 64 ms
80,000 KB |
testcase_42 | AC | 30 ms
39,168 KB |
testcase_43 | AC | 31 ms
38,528 KB |
testcase_44 | AC | 202 ms
233,216 KB |
testcase_45 | AC | 18 ms
24,448 KB |
testcase_46 | AC | 44 ms
54,912 KB |
testcase_47 | AC | 199 ms
226,432 KB |
testcase_48 | AC | 121 ms
143,232 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; }