結果

問題 No.1980 [Cherry 4th Tune D] 停止距離
ユーザー hamuhei4869hamuhei4869
提出日時 2022-03-24 04:16:33
言語 C++11
(gcc 11.4.0)
結果
TLE  
実行時間 -
コード長 771 bytes
コンパイル時間 1,326 ms
コンパイル使用メモリ 160,468 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-04-17 12:23:03
合計ジャッジ時間 7,019 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 4 ms
8,576 KB
testcase_01 TLE -
testcase_02 -- -
testcase_03 -- -
testcase_04 -- -
testcase_05 -- -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
testcase_24 -- -
testcase_25 -- -
testcase_26 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<bits/stdc++.h>

using namespace std;
using ll = long long;

int main(){
    int N;cin >> N;
    while(N--){
        string _T, _u, _L;
        cin >> _T >> _u >> _L;
        _T.erase(find(_T.begin(), _T.end(), '.'));
        _u.erase(find(_u.begin(), _u.end(), '.'));
        _L.erase(find(_L.begin(), _L.end(), '.'));

        ll T = stoi(_T);
        ll u = stoi(_u);
        ll L = stoi(_L);

        ll w = 20 * u;
        ll Tw36000 = T * w * 36000;
        ll magic = 3600 * 3600;
        ll Lw = L * w;
        ll left = Lw * magic;
        for(ll V = 600100;V >= 0;V--){
            if(left >= V * Tw36000 + V * V * 1000000){
                printf("%lld.%02lld\n", V / 100, V % 100);
                break; 
            }
        }
    }
    return 0;
}
0