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