#include #define FASTIO using namespace std; using ll = long long; using Vi = vector; using Vl = vector; using Pii = pair; using Pll = pair; constexpr int I_INF = numeric_limits::max(); constexpr ll L_INF = numeric_limits::max(); //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% void solve() { ll A, B; cin >> A >> B; if (A == B) { cout << A * 2 - 1 << endl; } else { cout << min(A, B) * 2 << endl; } } //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% int main() { #ifdef FASTIO cin.tie(0), cout.tie(0); ios::sync_with_stdio(false); #endif #ifdef FILEINPUT ifstream ifs("./in_out/input.txt"); cin.rdbuf(ifs.rdbuf()); #endif #ifdef FILEOUTPUT ofstream ofs("./in_out/output.txt"); cout.rdbuf(ofs.rdbuf()); #endif solve(); cout << flush; return 0; }