import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();

        if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        }
    }
} import java.util.Scanner; Scanner java.util public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();

        if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        }
    }
} Main public static void main(String[] args) {
        // write your code here
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();

        if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        }
    } main {
        // write your code here
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();

        if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        }
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int A = scanner.nextInt(); A scanner.nextInt() scanner.nextInt scanner int B = scanner.nextInt(); B scanner.nextInt() scanner.nextInt scanner if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        } A == B A B {
            System.out.println(A * 2);
        } System.out.println(A * 2) System.out.println System.out System System.out A * 2 A 2 {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        } if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            } A < B A B {
                int temp = B;
                B = A;
                A = temp;
            } int temp = B; temp B B = A B A A = temp A temp System.out.println((A - 1) + A) System.out.println System.out System System.out (A - 1) + A (A - 1) A 1 A String[] args args public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();

        if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        }
    }
} public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();

        if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        }
    }
} Main
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();

        if (A == B) {
            System.out.println(A * 2);
        } else {
            if (A < B) {
                int temp = B;
                B = A;
                A = temp;
            }
            System.out.println((A - 1) + A);
        }
    }
}
