結果

問題 No.2043 Ohuton and Makura
ユーザー a aa a
提出日時 2022-10-03 01:20:12
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 1,122 ms / 2,000 ms
コード長 239 bytes
コンパイル時間 105 ms
コンパイル使用メモリ 10,720 KB
実行使用メモリ 9,224 KB
最終ジャッジ日時 2023-08-26 22:44:00
合計ジャッジ時間 9,457 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 22 ms
9,048 KB
testcase_01 AC 22 ms
9,088 KB
testcase_02 AC 239 ms
9,216 KB
testcase_03 AC 48 ms
9,204 KB
testcase_04 AC 962 ms
9,224 KB
testcase_05 AC 700 ms
9,148 KB
testcase_06 AC 110 ms
9,156 KB
testcase_07 AC 1,053 ms
9,212 KB
testcase_08 AC 143 ms
9,040 KB
testcase_09 AC 265 ms
9,220 KB
testcase_10 AC 460 ms
9,224 KB
testcase_11 AC 692 ms
9,044 KB
testcase_12 AC 21 ms
9,116 KB
testcase_13 AC 21 ms
9,052 KB
testcase_14 AC 21 ms
9,016 KB
testcase_15 AC 21 ms
9,152 KB
testcase_16 AC 21 ms
9,024 KB
testcase_17 AC 1,031 ms
9,148 KB
testcase_18 AC 20 ms
9,164 KB
testcase_19 AC 1,122 ms
9,060 KB
testcase_20 AC 1,038 ms
9,164 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from decimal import Decimal
import math
a,b,s=list(map(int,input().split ()))
n=0
for i in range(1,s+1):
    bm=min(max(math.floor(s/i),0),b)
    n+=int((a-i+1)*(((b+1)*bm)-(bm*(bm+1)*Decimal('0.5'))))
    if i==a:
        break
print(n)

0