結果
問題 | No.920 あかあお |
ユーザー |
![]() |
提出日時 | 2020-03-10 19:02:26 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 242 bytes |
コンパイル時間 | 1,478 ms |
コンパイル使用メモリ | 166,528 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-15 23:32:58 |
合計ジャッジ時間 | 2,127 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 11 |
ソースコード
#include <bits/stdc++.h> using namespace std; int main(){ int a,b,c; int d=0; cin >> a>>b>>c; if(c<=abs(a-b)) d+= min(a,b)+c; else{ d += max(a,b); c-=abs(a-b); d +=c/2; } cout << d << endl; return 0; }