結果

問題 No.1139 Slime Race
ユーザー tyaro804tyaro804
提出日時 2020-08-08 18:24:02
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 75 ms / 2,000 ms
コード長 797 bytes
コンパイル時間 1,386 ms
コンパイル使用メモリ 166,864 KB
実行使用メモリ 4,868 KB
最終ジャッジ日時 2023-09-15 03:04:47
合計ジャッジ時間 3,274 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1 ms
4,380 KB
testcase_01 AC 1 ms
4,380 KB
testcase_02 AC 1 ms
4,380 KB
testcase_03 AC 1 ms
4,380 KB
testcase_04 AC 2 ms
4,376 KB
testcase_05 AC 1 ms
4,376 KB
testcase_06 AC 3 ms
4,380 KB
testcase_07 AC 1 ms
4,376 KB
testcase_08 AC 2 ms
4,376 KB
testcase_09 AC 2 ms
4,376 KB
testcase_10 AC 54 ms
4,868 KB
testcase_11 AC 47 ms
4,616 KB
testcase_12 AC 68 ms
4,564 KB
testcase_13 AC 2 ms
4,376 KB
testcase_14 AC 53 ms
4,612 KB
testcase_15 AC 60 ms
4,420 KB
testcase_16 AC 66 ms
4,652 KB
testcase_17 AC 55 ms
4,720 KB
testcase_18 AC 45 ms
4,376 KB
testcase_19 AC 31 ms
4,384 KB
testcase_20 AC 30 ms
4,380 KB
testcase_21 AC 42 ms
4,488 KB
testcase_22 AC 54 ms
4,628 KB
testcase_23 AC 75 ms
4,720 KB
testcase_24 AC 2 ms
4,380 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define repr(i, a, b) for(int i = a; i < b; i++)
#define  all(x) (x).begin(),(x).end()     // 昇順ソート
#define  rall(v) (v).rbegin(), (v).rend() // 降順ソート
#define  FastIO ios_base::sync_with_stdio(0),cin.tie(0),cout.tie(0)
typedef long long ll;
using P = pair<int,int>;
template<class T> bool chmax(T &a, const T &b) { if (a<b) { a=b; return true; } return false; }
template<class T> bool chmin(T &a, const T &b) { if (a>b) { a=b; return true; } return false; }

int main(){
    ll n, d;
    cin >> n >> d;
    vector<ll> x(n), v(n);
    rep(i,n) cin >> x[i];
    rep(i,n) cin >> v[i];
    ll sum = 0;
    rep(i,n) sum += v[i];
    cout << (d+(sum-1)) / sum << endl;
    return 0;
}
0