import java.util.Scanner;

public class Main {

	private static String halfSpace = " ";

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);

		String tmp = scanner.nextLine();

		scanner.close();

		String[] tmpStrs = tmp.split(halfSpace);

		int a_button = Integer.parseInt(tmpStrs[0]);

		int b_button = Integer.parseInt(tmpStrs[1]);

		int count = 2;

		int max = 0;

		for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		}

		System.out.println(max);
	}

} import java.util.Scanner; Scanner java.util public class Main {

	private static String halfSpace = " ";

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);

		String tmp = scanner.nextLine();

		scanner.close();

		String[] tmpStrs = tmp.split(halfSpace);

		int a_button = Integer.parseInt(tmpStrs[0]);

		int b_button = Integer.parseInt(tmpStrs[1]);

		int count = 2;

		int max = 0;

		for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		}

		System.out.println(max);
	}

} Main private static String halfSpace = " "; halfSpace " " public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);

		String tmp = scanner.nextLine();

		scanner.close();

		String[] tmpStrs = tmp.split(halfSpace);

		int a_button = Integer.parseInt(tmpStrs[0]);

		int b_button = Integer.parseInt(tmpStrs[1]);

		int count = 2;

		int max = 0;

		for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		}

		System.out.println(max);
	} main {
		Scanner scanner = new Scanner(System.in);

		String tmp = scanner.nextLine();

		scanner.close();

		String[] tmpStrs = tmp.split(halfSpace);

		int a_button = Integer.parseInt(tmpStrs[0]);

		int b_button = Integer.parseInt(tmpStrs[1]);

		int count = 2;

		int max = 0;

		for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		}

		System.out.println(max);
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) String tmp = scanner.nextLine(); tmp scanner.nextLine() scanner.nextLine scanner scanner.close() scanner.close scanner String[] tmpStrs = tmp.split(halfSpace); tmpStrs tmp.split(halfSpace) tmp.split tmp halfSpace int a_button = Integer.parseInt(tmpStrs[0]); a_button Integer.parseInt(tmpStrs[0]) Integer.parseInt Integer tmpStrs[0] tmpStrs 0 int b_button = Integer.parseInt(tmpStrs[1]); b_button Integer.parseInt(tmpStrs[1]) Integer.parseInt Integer tmpStrs[1] tmpStrs 1 int count = 2; count 2 int max = 0; max 0 for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		} int i = 0; int i = 0; i 0 i < count i count i++ i++ i {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		} {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		} if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			} a_button > b_button a_button b_button {
				max = max + a_button;
				a_button--;
			} max = max + a_button max max + a_button max a_button a_button-- a_button if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			} b_button > a_button b_button a_button {
				max = max + b_button;
				b_button--;
			} max = max + b_button max max + b_button max b_button b_button-- b_button {
				max = max + a_button;
			} max = max + a_button max max + a_button max a_button System.out.println(max) System.out.println System.out System System.out max String[] args args public class Main {

	private static String halfSpace = " ";

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);

		String tmp = scanner.nextLine();

		scanner.close();

		String[] tmpStrs = tmp.split(halfSpace);

		int a_button = Integer.parseInt(tmpStrs[0]);

		int b_button = Integer.parseInt(tmpStrs[1]);

		int count = 2;

		int max = 0;

		for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		}

		System.out.println(max);
	}

} public class Main {

	private static String halfSpace = " ";

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);

		String tmp = scanner.nextLine();

		scanner.close();

		String[] tmpStrs = tmp.split(halfSpace);

		int a_button = Integer.parseInt(tmpStrs[0]);

		int b_button = Integer.parseInt(tmpStrs[1]);

		int count = 2;

		int max = 0;

		for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		}

		System.out.println(max);
	}

} Main
import java.util.Scanner;

public class Main {

	private static String halfSpace = " ";

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);

		String tmp = scanner.nextLine();

		scanner.close();

		String[] tmpStrs = tmp.split(halfSpace);

		int a_button = Integer.parseInt(tmpStrs[0]);

		int b_button = Integer.parseInt(tmpStrs[1]);

		int count = 2;

		int max = 0;

		for(int i = 0; i < count; i++) {
			if(a_button > b_button) {
				max = max + a_button;
				a_button--;
			}else if(b_button > a_button) {
				max = max + b_button;
				b_button--;
			}else {
				max = max + a_button;
			}

		}

		System.out.println(max);
	}

}