import java.util.Scanner;

public class Main{
	public static void main(String[] args){
    Scanner sc= new Scanner(System.in);
    int A = sc.nextInt();
    int B = sc.nextInt();
    int c;
    int first;
    int second;
      
    if (B>=A){
     c=A;
     A=B;
     B=c;
    }
    first=A;
    A--;
      
    if (B>=A){
      c=A;
      A=B;
      B=c;
    }
      second=A;
      
      System.out.println(first+second);
      
    
    }
    } import java.util.Scanner; Scanner java.util public class Main{
	public static void main(String[] args){
    Scanner sc= new Scanner(System.in);
    int A = sc.nextInt();
    int B = sc.nextInt();
    int c;
    int first;
    int second;
      
    if (B>=A){
     c=A;
     A=B;
     B=c;
    }
    first=A;
    A--;
      
    if (B>=A){
      c=A;
      A=B;
      B=c;
    }
      second=A;
      
      System.out.println(first+second);
      
    
    }
    } Main public static void main(String[] args){
    Scanner sc= new Scanner(System.in);
    int A = sc.nextInt();
    int B = sc.nextInt();
    int c;
    int first;
    int second;
      
    if (B>=A){
     c=A;
     A=B;
     B=c;
    }
    first=A;
    A--;
      
    if (B>=A){
      c=A;
      A=B;
      B=c;
    }
      second=A;
      
      System.out.println(first+second);
      
    
    } main {
    Scanner sc= new Scanner(System.in);
    int A = sc.nextInt();
    int B = sc.nextInt();
    int c;
    int first;
    int second;
      
    if (B>=A){
     c=A;
     A=B;
     B=c;
    }
    first=A;
    A--;
      
    if (B>=A){
      c=A;
      A=B;
      B=c;
    }
      second=A;
      
      System.out.println(first+second);
      
    
    } Scanner sc= new Scanner(System.in); sc new Scanner(System.in) int A = sc.nextInt(); A sc.nextInt() sc.nextInt sc int B = sc.nextInt(); B sc.nextInt() sc.nextInt sc int c; c int first; first int second; second if (B>=A){
     c=A;
     A=B;
     B=c;
    } B>=A B A {
     c=A;
     A=B;
     B=c;
    } c=A c A A=B A B B=c B c first=A first A A-- A if (B>=A){
      c=A;
      A=B;
      B=c;
    } B>=A B A {
      c=A;
      A=B;
      B=c;
    } c=A c A A=B A B B=c B c second=A second A System.out.println(first+second) System.out.println System.out System System.out first+second first second String[] args args public class Main{
	public static void main(String[] args){
    Scanner sc= new Scanner(System.in);
    int A = sc.nextInt();
    int B = sc.nextInt();
    int c;
    int first;
    int second;
      
    if (B>=A){
     c=A;
     A=B;
     B=c;
    }
    first=A;
    A--;
      
    if (B>=A){
      c=A;
      A=B;
      B=c;
    }
      second=A;
      
      System.out.println(first+second);
      
    
    }
    } public class Main{
	public static void main(String[] args){
    Scanner sc= new Scanner(System.in);
    int A = sc.nextInt();
    int B = sc.nextInt();
    int c;
    int first;
    int second;
      
    if (B>=A){
     c=A;
     A=B;
     B=c;
    }
    first=A;
    A--;
      
    if (B>=A){
      c=A;
      A=B;
      B=c;
    }
      second=A;
      
      System.out.println(first+second);
      
    
    }
    } Main
import java.util.Scanner;

public class Main{
	public static void main(String[] args){
    Scanner sc= new Scanner(System.in);
    int A = sc.nextInt();
    int B = sc.nextInt();
    int c;
    int first;
    int second;
      
    if (B>=A){
     c=A;
     A=B;
     B=c;
    }
    first=A;
    A--;
      
    if (B>=A){
      c=A;
      A=B;
      B=c;
    }
      second=A;
      
      System.out.println(first+second);
      
    
    }
    }