import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] str = br.readLine().split(" ");
    int aButton = Integer.parseInt(str[0]);
    int bButton = Integer.parseInt(str[1]);
    int sum = 0;
    
    for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    }
    System.out.println(sum);
  }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.io.IOException; IOException java.io public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] str = br.readLine().split(" ");
    int aButton = Integer.parseInt(str[0]);
    int bButton = Integer.parseInt(str[1]);
    int sum = 0;
    
    for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    }
    System.out.println(sum);
  }
} Main public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] str = br.readLine().split(" ");
    int aButton = Integer.parseInt(str[0]);
    int bButton = Integer.parseInt(str[1]);
    int sum = 0;
    
    for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    }
    System.out.println(sum);
  } main {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] str = br.readLine().split(" ");
    int aButton = Integer.parseInt(str[0]);
    int bButton = Integer.parseInt(str[1]);
    int sum = 0;
    
    for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    }
    System.out.println(sum);
  } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String[] str = br.readLine().split(" "); str br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " int aButton = Integer.parseInt(str[0]); aButton Integer.parseInt(str[0]) Integer.parseInt Integer str[0] str 0 int bButton = Integer.parseInt(str[1]); bButton Integer.parseInt(str[1]) Integer.parseInt Integer str[1] str 1 int sum = 0; sum 0 for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    } int i = 0; int i = 0; i 0 i < 2 i 2 i++ i++ i {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    } {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    } if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      } aButton > bButton aButton bButton {
        sum += aButton;
        aButton--;
      } sum += aButton sum aButton aButton-- aButton {
        sum += bButton;
        bButton--;
      } sum += bButton sum bButton bButton-- bButton System.out.println(sum) System.out.println System.out System System.out sum String[] args args public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] str = br.readLine().split(" ");
    int aButton = Integer.parseInt(str[0]);
    int bButton = Integer.parseInt(str[1]);
    int sum = 0;
    
    for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    }
    System.out.println(sum);
  }
} public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] str = br.readLine().split(" ");
    int aButton = Integer.parseInt(str[0]);
    int bButton = Integer.parseInt(str[1]);
    int sum = 0;
    
    for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    }
    System.out.println(sum);
  }
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] str = br.readLine().split(" ");
    int aButton = Integer.parseInt(str[0]);
    int bButton = Integer.parseInt(str[1]);
    int sum = 0;
    
    for (int i = 0; i < 2; i++) {
      if (aButton > bButton) {
        sum += aButton;
        aButton--;
      } else {
        sum += bButton;
        bButton--;
      }
    }
    System.out.println(sum);
  }
}