import sequtils import strutils var n, m: int (n, m) = stdin.readLine.split.map parseInt echo n + m + max(0, abs(n - m) - 1)