結果

問題 No.2420 Simple Problem
ユーザー bortikbortik
提出日時 2023-08-16 04:39:12
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 450 bytes
コンパイル時間 2,203 ms
コンパイル使用メモリ 199,936 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-05-03 13:59:18
合計ジャッジ時間 10,006 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
6,812 KB
testcase_01 AC 27 ms
6,940 KB
testcase_02 AC 2 ms
5,376 KB
testcase_03 AC 11 ms
5,376 KB
testcase_04 AC 52 ms
5,376 KB
testcase_05 AC 38 ms
5,376 KB
testcase_06 AC 64 ms
5,376 KB
testcase_07 AC 65 ms
5,376 KB
testcase_08 AC 64 ms
5,376 KB
testcase_09 AC 64 ms
5,376 KB
testcase_10 AC 63 ms
5,376 KB
testcase_11 AC 64 ms
5,376 KB
testcase_12 AC 64 ms
5,376 KB
testcase_13 AC 64 ms
5,376 KB
testcase_14 AC 64 ms
5,376 KB
testcase_15 AC 62 ms
5,376 KB
testcase_16 AC 62 ms
5,376 KB
testcase_17 AC 65 ms
5,376 KB
testcase_18 AC 63 ms
5,376 KB
testcase_19 AC 65 ms
5,376 KB
testcase_20 AC 63 ms
5,376 KB
testcase_21 AC 63 ms
5,376 KB
testcase_22 AC 65 ms
5,376 KB
testcase_23 AC 65 ms
5,376 KB
testcase_24 AC 63 ms
5,376 KB
testcase_25 AC 63 ms
5,376 KB
testcase_26 WA -
testcase_27 WA -
testcase_28 WA -
testcase_29 WA -
testcase_30 WA -
testcase_31 WA -
testcase_32 AC 1 ms
5,376 KB
testcase_33 AC 26 ms
5,376 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>

using namespace std;

#define ll long long
#define rep(i, a, n) for (int i = (int)(a); i < (int)(n); i++)
#define rrep(i, n, a) for (int i = (int)(n); i >= (int)(a); i--)

void solve(){
    int n; cin >> n;
    rep(i,0,n){
        ll a,b; cin >> a >> b;
        double x = sqrt(a)+sqrt(b);
        cout << (int)x+1 << '\n';
    }
}

int main(){
    ios::sync_with_stdio(false);
    cin.tie(0);
    solve();

    return 0;
}
0