import java.util.Map;
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 cnt = 0;

        if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        }

    }


} import java.util.Map; Map java.util 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 cnt = 0;

        if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        }

    }


} Main public static void main(String[] args) {

        Scanner sc = new Scanner(System.in);

        int A = sc.nextInt();
        int B = sc.nextInt();
        int cnt = 0;

        if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        }

    } main {

        Scanner sc = new Scanner(System.in);

        int A = sc.nextInt();
        int B = sc.nextInt();
        int cnt = 0;

        if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        }

    } 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 cnt = 0; cnt 0 if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        } Math.abs(A - B) >= 2 Math.abs(A - B) Math.abs Math A - B A B 2 {
            System.out.println(Math.max(A,B) * 2 - 1);
        } System.out.println(Math.max(A,B) * 2 - 1) System.out.println System.out System System.out Math.max(A,B) * 2 - 1 Math.max(A,B) * 2 Math.max(A,B) Math.max Math A B 2 1 if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        } Math.abs(A - B) == 1 Math.abs(A - B) Math.abs Math A - B A B 1 {
            System.out.println(A+B);
        } System.out.println(A+B) System.out.println System.out System System.out A+B A B if(Math.abs(A-B)==0){
            System.out.println(A+B);
        } Math.abs(A-B)==0 Math.abs(A-B) Math.abs Math A-B A B 0 {
            System.out.println(A+B);
        } System.out.println(A+B) System.out.println System.out System System.out A+B A B 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 cnt = 0;

        if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        }

    }


} public class Main {

    public static void main(String[] args) {

        Scanner sc = new Scanner(System.in);

        int A = sc.nextInt();
        int B = sc.nextInt();
        int cnt = 0;

        if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        }

    }


} Main
import java.util.Map;
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 cnt = 0;

        if (Math.abs(A - B) >= 2) {
            System.out.println(Math.max(A,B) * 2 - 1);
        } else if (Math.abs(A - B) == 1) {
            System.out.println(A+B);
        }else if(Math.abs(A-B)==0){
            System.out.println(A+B);
        }

    }


}
