import java.util.Scanner;

public class Main {
  public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    }
  }
} import java.util.Scanner; Scanner java.util public class Main {
  public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    }
  }
} Main public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    }
  } main {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    }
  } Scanner in = new Scanner(System.in); in new Scanner(System.in) while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    } in.hasNext() in.hasNext in {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    } int A = in.nextInt(); A in.nextInt() in.nextInt in int B = in.nextInt(); B in.nextInt() in.nextInt in int large = Math.max(A, B); large Math.max(A, B) Math.max Math A B int small = Math.min(A, B); small Math.min(A, B) Math.min Math A B int X = large--; X large-- large if (large < small) {
          X += small;
      } else {
          X += large;
      } large < small large small {
          X += small;
      } X += small X small {
          X += large;
      } X += large X large System.out.println(X) System.out.println System.out System System.out X String[] args args public class Main {
  public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    }
  }
} public class Main {
  public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    }
  }
} Main
import java.util.Scanner;

public class Main {
  public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int large = Math.max(A, B);
      int small = Math.min(A, B);
      int X = large--;

      if (large < small) {
          X += small;
      } else {
          X += large;
      }

      System.out.println(X);
    }
  }
}