
import java.util.Scanner;

public class Main {
    public static void main(final String[] args) {
        final Scanner scanner = new Scanner(System.in);
        final int[] a = {scanner.nextInt()};
        final int[] b = {scanner.nextInt()};

        System.out.println(get(a, b) + get(a, b));
    }

    private static int get(final int[] a, final int[] b) {
        if (a[0] > b[0]) {
            return a[0]--;
        }

        return b[0]--;
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(final String[] args) {
        final Scanner scanner = new Scanner(System.in);
        final int[] a = {scanner.nextInt()};
        final int[] b = {scanner.nextInt()};

        System.out.println(get(a, b) + get(a, b));
    }

    private static int get(final int[] a, final int[] b) {
        if (a[0] > b[0]) {
            return a[0]--;
        }

        return b[0]--;
    }
} Main public static void main(final String[] args) {
        final Scanner scanner = new Scanner(System.in);
        final int[] a = {scanner.nextInt()};
        final int[] b = {scanner.nextInt()};

        System.out.println(get(a, b) + get(a, b));
    } main {
        final Scanner scanner = new Scanner(System.in);
        final int[] a = {scanner.nextInt()};
        final int[] b = {scanner.nextInt()};

        System.out.println(get(a, b) + get(a, b));
    } final Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) final int[] a = {scanner.nextInt()}; a {scanner.nextInt()} scanner.nextInt() scanner.nextInt scanner final int[] b = {scanner.nextInt()}; b {scanner.nextInt()} scanner.nextInt() scanner.nextInt scanner System.out.println(get(a, b) + get(a, b)) System.out.println System.out System System.out get(a, b) + get(a, b) get(a, b) get a b get(a, b) get a b final String[] args args private static int get(final int[] a, final int[] b) {
        if (a[0] > b[0]) {
            return a[0]--;
        }

        return b[0]--;
    } get {
        if (a[0] > b[0]) {
            return a[0]--;
        }

        return b[0]--;
    } if (a[0] > b[0]) {
            return a[0]--;
        } a[0] > b[0] a[0] a 0 b[0] b 0 {
            return a[0]--;
        } return a[0]--; a[0]-- a[0] a 0 return b[0]--; b[0]-- b[0] b 0 final int[] a a final int[] b b public class Main {
    public static void main(final String[] args) {
        final Scanner scanner = new Scanner(System.in);
        final int[] a = {scanner.nextInt()};
        final int[] b = {scanner.nextInt()};

        System.out.println(get(a, b) + get(a, b));
    }

    private static int get(final int[] a, final int[] b) {
        if (a[0] > b[0]) {
            return a[0]--;
        }

        return b[0]--;
    }
} public class Main {
    public static void main(final String[] args) {
        final Scanner scanner = new Scanner(System.in);
        final int[] a = {scanner.nextInt()};
        final int[] b = {scanner.nextInt()};

        System.out.println(get(a, b) + get(a, b));
    }

    private static int get(final int[] a, final int[] b) {
        if (a[0] > b[0]) {
            return a[0]--;
        }

        return b[0]--;
    }
} Main

import java.util.Scanner;

public class Main {
    public static void main(final String[] args) {
        final Scanner scanner = new Scanner(System.in);
        final int[] a = {scanner.nextInt()};
        final int[] b = {scanner.nextInt()};

        System.out.println(get(a, b) + get(a, b));
    }

    private static int get(final int[] a, final int[] b) {
        if (a[0] > b[0]) {
            return a[0]--;
        }

        return b[0]--;
    }
}
