import java.util.*;

class Main{
    public static void main(String arg[]){
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
      
        int sum = A + B;
        int difference = A - B;
        int product = A * B;
        
        //上記の最大値を出力
        System.out.println(Math.max(product, Math.max(sum, difference)));
    }
} import java.util.*; util.* java class Main{
    public static void main(String arg[]){
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
      
        int sum = A + B;
        int difference = A - B;
        int product = A * B;
        
        //上記の最大値を出力
        System.out.println(Math.max(product, Math.max(sum, difference)));
    }
} Main public static void main(String arg[]){
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
      
        int sum = A + B;
        int difference = A - B;
        int product = A * B;
        
        //上記の最大値を出力
        System.out.println(Math.max(product, Math.max(sum, difference)));
    } main {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
      
        int sum = A + B;
        int difference = A - B;
        int product = A * B;
        
        //上記の最大値を出力
        System.out.println(Math.max(product, Math.max(sum, difference)));
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int A = scanner.nextInt(); A scanner.nextInt() scanner.nextInt scanner int B = scanner.nextInt(); B scanner.nextInt() scanner.nextInt scanner int sum = A + B; sum A + B A B int difference = A - B; difference A - B A B int product = A * B; product A * B A B System.out.println(Math.max(product, Math.max(sum, difference))) System.out.println System.out System System.out Math.max(product, Math.max(sum, difference)) Math.max Math product Math.max(sum, difference) Math.max Math sum difference String arg[] arg
import java.util.*;

class Main{
    public static void main(String arg[]){
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
      
        int sum = A + B;
        int difference = A - B;
        int product = A * B;
        
        //上記の最大値を出力
        System.out.println(Math.max(product, Math.max(sum, difference)));
    }
}