結果
| 問題 |
No.920 あかあお
|
| コンテスト | |
| ユーザー |
kpinkcat
|
| 提出日時 | 2023-07-26 02:27:48 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 14 ms / 2,000 ms |
| コード長 | 370 bytes |
| コンパイル時間 | 878 ms |
| コンパイル使用メモリ | 103,436 KB |
| 最終ジャッジ日時 | 2025-02-15 19:11:08 |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 11 |
ソースコード
#include<iostream>
#include<iomanip>
#include<string>
#include<algorithm>
#include<vector>
#include<set>
#include<list>
#include<queue>
#include<math.h>
#include<bitset>
using namespace std;
int main(){
int x, y, z;
cin >> x >> y >> z;
if ((min(x, y)+z) - max(x, y)> 0) cout << max(x, y) + (z -abs(x-y))/2 << endl;
else cout << min(x, y) + z << endl;
}
kpinkcat