rogram main
  implicit none
  integer A, B
  read(*, *) A, B
  if (A < B) then
    write(*, '(i0)') 2*A - 1
  else if (A > B) then
    write(*, '(i0)') 2*B - 1
  else
    write(*, '(i0)') A + B
  end if
end program main