import java.io.*;
import java.util.*;

public class Main {
  
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int A  = sc.nextInt(), B = sc.nextInt();
    int opt1 = A + A - 1;
    int opt2 = B + B - 1;
    int opt3 = A + B;
    System.out.println(Math.max(opt1, Math.max(opt2, opt3)));
  }
} import java.io.*; io.* java import java.util.*; util.* java public class Main {
  
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int A  = sc.nextInt(), B = sc.nextInt();
    int opt1 = A + A - 1;
    int opt2 = B + B - 1;
    int opt3 = A + B;
    System.out.println(Math.max(opt1, Math.max(opt2, opt3)));
  }
} Main public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int A  = sc.nextInt(), B = sc.nextInt();
    int opt1 = A + A - 1;
    int opt2 = B + B - 1;
    int opt3 = A + B;
    System.out.println(Math.max(opt1, Math.max(opt2, opt3)));
  } main {
    Scanner sc = new Scanner(System.in);
    int A  = sc.nextInt(), B = sc.nextInt();
    int opt1 = A + A - 1;
    int opt2 = B + B - 1;
    int opt3 = A + B;
    System.out.println(Math.max(opt1, Math.max(opt2, opt3)));
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int A  = sc.nextInt() A sc.nextInt() sc.nextInt sc B = sc.nextInt(); B sc.nextInt() sc.nextInt sc int opt1 = A + A - 1; opt1 A + A - 1 A + A A A 1 int opt2 = B + B - 1; opt2 B + B - 1 B + B B B 1 int opt3 = A + B; opt3 A + B A B System.out.println(Math.max(opt1, Math.max(opt2, opt3))) System.out.println System.out System System.out Math.max(opt1, Math.max(opt2, opt3)) Math.max Math opt1 Math.max(opt2, opt3) Math.max Math opt2 opt3 String[] args args public class Main {
  
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int A  = sc.nextInt(), B = sc.nextInt();
    int opt1 = A + A - 1;
    int opt2 = B + B - 1;
    int opt3 = A + B;
    System.out.println(Math.max(opt1, Math.max(opt2, opt3)));
  }
} public class Main {
  
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int A  = sc.nextInt(), B = sc.nextInt();
    int opt1 = A + A - 1;
    int opt2 = B + B - 1;
    int opt3 = A + B;
    System.out.println(Math.max(opt1, Math.max(opt2, opt3)));
  }
} Main
import java.io.*;
import java.util.*;

public class Main {
  
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int A  = sc.nextInt(), B = sc.nextInt();
    int opt1 = A + A - 1;
    int opt2 = B + B - 1;
    int opt3 = A + B;
    System.out.println(Math.max(opt1, Math.max(opt2, opt3)));
  }
}
