Submission #30766


ソースコード

1
2
3
4
m,p,i;d[2222];main(t){
for(scanf("%d%*d",&t);~scanf("%d%d",&m,&p);)for(i=t;i-->0;)d[i+m]=fmax(d[i+m],d[i]+p);
printf("%d\n",d[t]);
}

ステータス

項目 データ
問題 0170 - テスト勉強
ユーザー名 kotatsugame
投稿日時 2018-02-06 04:26:29
言語 C
状態 Accepted
得点 10
ソースコード長 137 Byte
最大実行時間 29 ms
最大メモリ使用量 616 KB

セット

セット 得点 Cases
1 ALL 10 / 10 *

テストケース

ファイル名 状態 実行時間 メモリ使用量 #
in1.txt AC 25 ms 380 KB
1
in2.txt AC 21 ms 324 KB
1
in3.txt AC 29 ms 376 KB
1
in4.txt AC 13 ms 428 KB
1
in5.txt AC 19 ms 476 KB
1
in6.txt AC 16 ms 528 KB
1
in7.txt AC 16 ms 572 KB
1
in8.txt AC 25 ms 616 KB
1
in9.txt AC 20 ms 440 KB
1
in10.txt AC 20 ms 308 KB
1