A, B = map(int, input().split()) if A == B: print(A + B - 1) else: A, B = min(A, B), max(A, B) ans = 2*A print(ans)