結果

問題 No.1057 素敵な日
ユーザー T.StreamT.Stream
提出日時 2021-03-15 20:34:36
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 183 bytes
コンパイル時間 1,825 ms
コンパイル使用メモリ 192,304 KB
最終ジャッジ日時 2025-01-19 17:20:31
ジャッジサーバーID
(参考情報)
judge4 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 7
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

int main() {
	int a,b;
	cin >> a >> b;
	if(a>=b){
		cout << b+min(a-1,b);
	}else{
		cout << a+min(b-1,a);
	}
	cout << endl;
	return 0;
}
0