結果

問題 No.1980 [Cherry 4th Tune D] 停止距離
ユーザー pitPpitP
提出日時 2022-06-17 21:49:29
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 547 bytes
コンパイル時間 399 ms
コンパイル使用メモリ 82,432 KB
実行使用メモリ 77,720 KB
最終ジャッジ日時 2024-04-17 13:32:08
合計ジャッジ時間 27,735 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 37 ms
52,480 KB
testcase_01 AC 283 ms
77,196 KB
testcase_02 WA -
testcase_03 AC 601 ms
77,440 KB
testcase_04 AC 228 ms
77,440 KB
testcase_05 AC 746 ms
77,312 KB
testcase_06 AC 1,089 ms
77,720 KB
testcase_07 AC 1,099 ms
77,412 KB
testcase_08 WA -
testcase_09 AC 1,117 ms
76,928 KB
testcase_10 AC 1,085 ms
77,440 KB
testcase_11 AC 1,108 ms
77,184 KB
testcase_12 AC 1,099 ms
77,152 KB
testcase_13 AC 1,104 ms
76,928 KB
testcase_14 AC 1,093 ms
77,048 KB
testcase_15 AC 1,113 ms
76,988 KB
testcase_16 AC 1,077 ms
77,020 KB
testcase_17 AC 1,098 ms
76,684 KB
testcase_18 AC 1,079 ms
76,672 KB
testcase_19 WA -
testcase_20 AC 1,105 ms
76,672 KB
testcase_21 AC 1,076 ms
76,544 KB
testcase_22 AC 1,093 ms
76,416 KB
testcase_23 WA -
testcase_24 AC 1,079 ms
76,416 KB
testcase_25 AC 1,095 ms
76,544 KB
testcase_26 AC 37 ms
52,480 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
eps = pow(10,-12)
for _ in range(n):
    t,mu,l = map(float,input().split())
    right = 5100.0
    left = 0.0
    while abs(right - left) > eps:
        mid = (right+left)/2
        now = (1/3.6*mid*t + 1/3.6/3.6*mid*mid/20/mu)
        if now >= l:
            right = mid
        else:
            left = mid
    moji = str(right)
    if 0 <= right < 10.0:
        print(moji[:4])
    elif 10.0 <= right < 100.0:
        print(moji[:5])
    elif 100.0 <= right < 1000.0:
        print(moji[:6])
    else:
        print(moji[:7])
0