import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String[] tmp = sc.nextLine().split(" ");
        int a = Integer.valueOf(tmp[0]);
        int b = Integer.valueOf(tmp[1]);
        int sum = judge(a, b);

        if (a < b) {
            b--;
        } else {
            a--;
        }
        sum += judge(a, b);
        System.out.println(sum);
    }

    public static int judge(int a, int b) {
        int res = 0;
        if (a < b) {
            res = b;
        } else {
            res = a;
        }
        return res;
    }
} import java.util.Scanner; Scanner java.util public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String[] tmp = sc.nextLine().split(" ");
        int a = Integer.valueOf(tmp[0]);
        int b = Integer.valueOf(tmp[1]);
        int sum = judge(a, b);

        if (a < b) {
            b--;
        } else {
            a--;
        }
        sum += judge(a, b);
        System.out.println(sum);
    }

    public static int judge(int a, int b) {
        int res = 0;
        if (a < b) {
            res = b;
        } else {
            res = a;
        }
        return res;
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String[] tmp = sc.nextLine().split(" ");
        int a = Integer.valueOf(tmp[0]);
        int b = Integer.valueOf(tmp[1]);
        int sum = judge(a, b);

        if (a < b) {
            b--;
        } else {
            a--;
        }
        sum += judge(a, b);
        System.out.println(sum);
    } main {
        Scanner sc = new Scanner(System.in);
        String[] tmp = sc.nextLine().split(" ");
        int a = Integer.valueOf(tmp[0]);
        int b = Integer.valueOf(tmp[1]);
        int sum = judge(a, b);

        if (a < b) {
            b--;
        } else {
            a--;
        }
        sum += judge(a, b);
        System.out.println(sum);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String[] tmp = sc.nextLine().split(" "); tmp sc.nextLine().split(" ") sc.nextLine().split sc.nextLine() sc.nextLine sc " " int a = Integer.valueOf(tmp[0]); a Integer.valueOf(tmp[0]) Integer.valueOf Integer tmp[0] tmp 0 int b = Integer.valueOf(tmp[1]); b Integer.valueOf(tmp[1]) Integer.valueOf Integer tmp[1] tmp 1 int sum = judge(a, b); sum judge(a, b) judge a b if (a < b) {
            b--;
        } else {
            a--;
        } a < b a b {
            b--;
        } b-- b {
            a--;
        } a-- a sum += judge(a, b) sum judge(a, b) judge a b System.out.println(sum) System.out.println System.out System System.out sum String[] args args public static int judge(int a, int b) {
        int res = 0;
        if (a < b) {
            res = b;
        } else {
            res = a;
        }
        return res;
    } judge {
        int res = 0;
        if (a < b) {
            res = b;
        } else {
            res = a;
        }
        return res;
    } int res = 0; res 0 if (a < b) {
            res = b;
        } else {
            res = a;
        } a < b a b {
            res = b;
        } res = b res b {
            res = a;
        } res = a res a return res; res int a a int b b public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String[] tmp = sc.nextLine().split(" ");
        int a = Integer.valueOf(tmp[0]);
        int b = Integer.valueOf(tmp[1]);
        int sum = judge(a, b);

        if (a < b) {
            b--;
        } else {
            a--;
        }
        sum += judge(a, b);
        System.out.println(sum);
    }

    public static int judge(int a, int b) {
        int res = 0;
        if (a < b) {
            res = b;
        } else {
            res = a;
        }
        return res;
    }
} public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String[] tmp = sc.nextLine().split(" ");
        int a = Integer.valueOf(tmp[0]);
        int b = Integer.valueOf(tmp[1]);
        int sum = judge(a, b);

        if (a < b) {
            b--;
        } else {
            a--;
        }
        sum += judge(a, b);
        System.out.println(sum);
    }

    public static int judge(int a, int b) {
        int res = 0;
        if (a < b) {
            res = b;
        } else {
            res = a;
        }
        return res;
    }
} Main
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String[] tmp = sc.nextLine().split(" ");
        int a = Integer.valueOf(tmp[0]);
        int b = Integer.valueOf(tmp[1]);
        int sum = judge(a, b);

        if (a < b) {
            b--;
        } else {
            a--;
        }
        sum += judge(a, b);
        System.out.println(sum);
    }

    public static int judge(int a, int b) {
        int res = 0;
        if (a < b) {
            res = b;
        } else {
            res = a;
        }
        return res;
    }
}
