結果

問題 No.909 たぴの配置
ユーザー 🍮かんプリン🍮かんプリン
提出日時 2019-10-18 22:31:13
言語 C++11
(gcc 11.4.0)
結果
AC  
実行時間 362 ms / 3,000 ms
コード長 584 bytes
コンパイル時間 1,847 ms
コンパイル使用メモリ 145,296 KB
実行使用メモリ 4,724 KB
最終ジャッジ日時 2023-09-08 00:23:53
合計ジャッジ時間 8,099 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1 ms
4,384 KB
testcase_01 AC 1 ms
4,380 KB
testcase_02 AC 1 ms
4,380 KB
testcase_03 AC 1 ms
4,376 KB
testcase_04 AC 2 ms
4,376 KB
testcase_05 AC 355 ms
4,612 KB
testcase_06 AC 362 ms
4,608 KB
testcase_07 AC 337 ms
4,384 KB
testcase_08 AC 362 ms
4,724 KB
testcase_09 AC 361 ms
4,612 KB
testcase_10 AC 336 ms
4,464 KB
testcase_11 AC 328 ms
4,380 KB
testcase_12 AC 344 ms
4,616 KB
testcase_13 AC 356 ms
4,616 KB
testcase_14 AC 333 ms
4,380 KB
testcase_15 AC 348 ms
4,616 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include "bits/stdc++.h"
#define REP(i, n) for(int i = 0; i < int(n); i++)
#define FOR(i,n,m) for(int i = int(n); i < int(m); i++)
using namespace std;
typedef long long ll;
const int MOD = 1e9 + 7;
const int INF = 1e9 + 6;
const ll LLINF = 1e18 + 1;

int main() {
    int n; cin >> n;
    vector<int> x(n), y(n);
    REP(i, n) cin >> x[i];
    REP(i, n) cin >> y[i];
    int s = INF;
    REP(i, n) {
        s = min(s, x[i] + y[i]);
    }
    cout << s << endl;
    cout << 0 << endl;
    REP(i, n) {
        cout << min(s, x[i]) << endl;
    }
    cout << s << endl;
    return 0;
}
0