#include <bits/stdc++.h>
#define rep(i,n) for (int (i) = 0; (i) < (n); i++)
#define ll long long
using namespace std;

int main() {
  int n,m;
  cin >> n >> m;
  if(n == m){
    cout << 2*m;
  }
  else{
    cout << 2*max(m,n)-1;
  }
}
#include "bits/stdc++.h"
using namespace std;

int main() {
	int A,B;
	cin >> A>>B;
	int ans = 0;
	for (int n = 0;n<2; ++n) {
		if (A > B) {
			ans += A;
			--A;
		}
		else {
			ans += B;
			--B;
		}
	}
	cout << ans<<endl;
	return 0;
}