import java.util.Scanner;
public class Main {
	@SuppressWarnings("resource")
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		int total = 0;
		if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		}
		System.out.println(total);

	}
	} import java.util.Scanner; Scanner java.util public class Main {
	@SuppressWarnings("resource")
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		int total = 0;
		if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		}
		System.out.println(total);

	}
	} Main @SuppressWarnings("resource")
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		int total = 0;
		if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		}
		System.out.println(total);

	} main {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		int total = 0;
		if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		}
		System.out.println(total);

	} 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 total = 0; total 0 if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		} a>b a b {
			total+=2*a-1;
		} total+=2*a-1 total 2*a-1 2*a 2 a 1 if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		} a==b a b {
			total+=2*a;
		} total+=2*a total 2*a 2 a {
			total+=2*b-1;
		} total+=2*b-1 total 2*b-1 2*b 2 b 1 System.out.println(total) System.out.println System.out System System.out total String[] args args public class Main {
	@SuppressWarnings("resource")
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		int total = 0;
		if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		}
		System.out.println(total);

	}
	} public class Main {
	@SuppressWarnings("resource")
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		int total = 0;
		if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		}
		System.out.println(total);

	}
	} Main
import java.util.Scanner;
public class Main {
	@SuppressWarnings("resource")
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		int total = 0;
		if(a>b) {
			total+=2*a-1;
		}else if(a==b) {
			total+=2*a;
		}else {
			total+=2*b-1;
		}
		System.out.println(total);

	}
	}
