結果

問題 No.1980 [Cherry 4th Tune D] 停止距離
ユーザー sotanishysotanishy
提出日時 2022-06-17 22:35:50
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 525 ms / 3,000 ms
コード長 497 bytes
コンパイル時間 341 ms
コンパイル使用メモリ 82,372 KB
実行使用メモリ 80,892 KB
最終ジャッジ日時 2024-04-17 14:51:21
合計ジャッジ時間 14,333 ms
ジャッジサーバーID
(参考情報)
judge4 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 31 ms
53,408 KB
testcase_01 AC 137 ms
76,712 KB
testcase_02 AC 373 ms
79,064 KB
testcase_03 AC 280 ms
78,088 KB
testcase_04 AC 115 ms
76,496 KB
testcase_05 AC 341 ms
79,104 KB
testcase_06 AC 497 ms
80,616 KB
testcase_07 AC 492 ms
80,592 KB
testcase_08 AC 521 ms
80,548 KB
testcase_09 AC 505 ms
80,620 KB
testcase_10 AC 502 ms
80,540 KB
testcase_11 AC 501 ms
80,208 KB
testcase_12 AC 517 ms
80,892 KB
testcase_13 AC 523 ms
80,340 KB
testcase_14 AC 525 ms
80,468 KB
testcase_15 AC 504 ms
80,540 KB
testcase_16 AC 500 ms
79,512 KB
testcase_17 AC 474 ms
79,248 KB
testcase_18 AC 501 ms
79,268 KB
testcase_19 AC 496 ms
79,168 KB
testcase_20 AC 483 ms
79,272 KB
testcase_21 AC 480 ms
79,320 KB
testcase_22 AC 475 ms
79,216 KB
testcase_23 AC 477 ms
79,724 KB
testcase_24 AC 482 ms
79,268 KB
testcase_25 AC 471 ms
79,312 KB
testcase_26 AC 33 ms
52,644 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline

N = int(input())
for _ in range(N):
    T, m, L = input().rstrip().split()
    T = int(T[:-3] + T[-2:])
    m = int(m[:-3] + m[-2:])
    L = int(L[:-3] + L[-2:])
    lb, ub = 0, 10**10
    while ub - lb > 1:
        v = (lb + ub) // 2
        if 20*m*360*T*v + 10000*v**2 <= 20*m*360**2*L:
            lb = v
        else:
            ub = v
    ans = str(lb)
    while len(ans) < 3:
        ans = "0" + ans
    ans = ans[:-2] + "." + ans[-2:]
    print(ans)
0