a = [int(i) for i in input().split()] a.sort() a[1] = min(a[0]+1,a[1]) print(a[0]+a[1]-1)