結果
問題 | No.909 たぴの配置 |
ユーザー |
|
提出日時 | 2020-08-09 00:30:50 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 401 ms / 3,000 ms |
コード長 | 472 bytes |
コンパイル時間 | 3,819 ms |
コンパイル使用メモリ | 193,876 KB |
最終ジャッジ日時 | 2025-01-12 19:10:19 |
ジャッジサーバーID (参考情報) |
judge1 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 13 |
ソースコード
#include <bits/stdc++.h>using namespace std;#define REP(i,n) for(int i=0; i<(int)(n); i++)const int INF = 1<<30;int main() {ios_base::sync_with_stdio(0);cin.tie(0);int n;cin >> n;vector<int> x(n), y(n);REP (i, n) cin >> x[i];REP (i, n) cin >> y[i];int ret = INF;REP (i, n) ret = min(ret, x[i] + y[i]);cout << ret << endl;cout << 0 << endl;REP (i, n)cout << min(x[i], ret) << endl;cout << ret << endl;return 0;}