
import java.util.Scanner;
import java.math.BigInteger;


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

		int a,b,c,d;
		a = b = c = d = 0;

		if(input.hasNextInt())a = input.nextInt();
		if(input.hasNextInt())b = input.nextInt();	
		if(input.hasNextInt())c = input.nextInt();
		if(input.hasNextInt())d = input.nextInt();


		BigInteger A = BigInteger.valueOf(a);
		BigInteger B = BigInteger.valueOf(b);
		BigInteger max1 = A.multiply(BigInteger.valueOf(c));
		BigInteger max2 = A.multiply(BigInteger.valueOf(d));
		BigInteger max3 = B.multiply(BigInteger.valueOf(c));
		BigInteger max4 = B.multiply(BigInteger.valueOf(d));

		int ca = max1.compareTo(max2);
		int cb = max3.compareTo(max4);

		BigInteger f1,f2;
		if(ca>0)f1 = max1;
		else f1 = max2;
		if(cb>0)f2 = max3;
		else f2 = max4;

		int cf = f1.compareTo(f2);
		if(cf>0)System.out.println(f1);
		else System.out.println(f2);


		
	}
} import java.util.Scanner; Scanner java.util import java.math.BigInteger; BigInteger java.math class Main{
	public static void main(String args[]){
		
		Scanner input = new Scanner(System.in);

		int a,b,c,d;
		a = b = c = d = 0;

		if(input.hasNextInt())a = input.nextInt();
		if(input.hasNextInt())b = input.nextInt();	
		if(input.hasNextInt())c = input.nextInt();
		if(input.hasNextInt())d = input.nextInt();


		BigInteger A = BigInteger.valueOf(a);
		BigInteger B = BigInteger.valueOf(b);
		BigInteger max1 = A.multiply(BigInteger.valueOf(c));
		BigInteger max2 = A.multiply(BigInteger.valueOf(d));
		BigInteger max3 = B.multiply(BigInteger.valueOf(c));
		BigInteger max4 = B.multiply(BigInteger.valueOf(d));

		int ca = max1.compareTo(max2);
		int cb = max3.compareTo(max4);

		BigInteger f1,f2;
		if(ca>0)f1 = max1;
		else f1 = max2;
		if(cb>0)f2 = max3;
		else f2 = max4;

		int cf = f1.compareTo(f2);
		if(cf>0)System.out.println(f1);
		else System.out.println(f2);


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

		int a,b,c,d;
		a = b = c = d = 0;

		if(input.hasNextInt())a = input.nextInt();
		if(input.hasNextInt())b = input.nextInt();	
		if(input.hasNextInt())c = input.nextInt();
		if(input.hasNextInt())d = input.nextInt();


		BigInteger A = BigInteger.valueOf(a);
		BigInteger B = BigInteger.valueOf(b);
		BigInteger max1 = A.multiply(BigInteger.valueOf(c));
		BigInteger max2 = A.multiply(BigInteger.valueOf(d));
		BigInteger max3 = B.multiply(BigInteger.valueOf(c));
		BigInteger max4 = B.multiply(BigInteger.valueOf(d));

		int ca = max1.compareTo(max2);
		int cb = max3.compareTo(max4);

		BigInteger f1,f2;
		if(ca>0)f1 = max1;
		else f1 = max2;
		if(cb>0)f2 = max3;
		else f2 = max4;

		int cf = f1.compareTo(f2);
		if(cf>0)System.out.println(f1);
		else System.out.println(f2);


		
	} main {
		
		Scanner input = new Scanner(System.in);

		int a,b,c,d;
		a = b = c = d = 0;

		if(input.hasNextInt())a = input.nextInt();
		if(input.hasNextInt())b = input.nextInt();	
		if(input.hasNextInt())c = input.nextInt();
		if(input.hasNextInt())d = input.nextInt();


		BigInteger A = BigInteger.valueOf(a);
		BigInteger B = BigInteger.valueOf(b);
		BigInteger max1 = A.multiply(BigInteger.valueOf(c));
		BigInteger max2 = A.multiply(BigInteger.valueOf(d));
		BigInteger max3 = B.multiply(BigInteger.valueOf(c));
		BigInteger max4 = B.multiply(BigInteger.valueOf(d));

		int ca = max1.compareTo(max2);
		int cb = max3.compareTo(max4);

		BigInteger f1,f2;
		if(ca>0)f1 = max1;
		else f1 = max2;
		if(cb>0)f2 = max3;
		else f2 = max4;

		int cf = f1.compareTo(f2);
		if(cf>0)System.out.println(f1);
		else System.out.println(f2);


		
	} Scanner input = new Scanner(System.in); input new Scanner(System.in) int a a b b c c d; d a = b = c = d = 0 a b = c = d = 0 b c = d = 0 c d = 0 d 0 if(input.hasNextInt())a = input.nextInt(); input.hasNextInt() input.hasNextInt input a = input.nextInt() a input.nextInt() input.nextInt input if(input.hasNextInt())b = input.nextInt(); input.hasNextInt() input.hasNextInt input b = input.nextInt() b input.nextInt() input.nextInt input if(input.hasNextInt())c = input.nextInt(); input.hasNextInt() input.hasNextInt input c = input.nextInt() c input.nextInt() input.nextInt input if(input.hasNextInt())d = input.nextInt(); input.hasNextInt() input.hasNextInt input d = input.nextInt() d input.nextInt() input.nextInt input BigInteger A = BigInteger.valueOf(a); A BigInteger.valueOf(a) BigInteger.valueOf BigInteger a BigInteger B = BigInteger.valueOf(b); B BigInteger.valueOf(b) BigInteger.valueOf BigInteger b BigInteger max1 = A.multiply(BigInteger.valueOf(c)); max1 A.multiply(BigInteger.valueOf(c)) A.multiply A BigInteger.valueOf(c) BigInteger.valueOf BigInteger c BigInteger max2 = A.multiply(BigInteger.valueOf(d)); max2 A.multiply(BigInteger.valueOf(d)) A.multiply A BigInteger.valueOf(d) BigInteger.valueOf BigInteger d BigInteger max3 = B.multiply(BigInteger.valueOf(c)); max3 B.multiply(BigInteger.valueOf(c)) B.multiply B BigInteger.valueOf(c) BigInteger.valueOf BigInteger c BigInteger max4 = B.multiply(BigInteger.valueOf(d)); max4 B.multiply(BigInteger.valueOf(d)) B.multiply B BigInteger.valueOf(d) BigInteger.valueOf BigInteger d int ca = max1.compareTo(max2); ca max1.compareTo(max2) max1.compareTo max1 max2 int cb = max3.compareTo(max4); cb max3.compareTo(max4) max3.compareTo max3 max4 BigInteger f1 f1 f2; f2 if(ca>0)f1 = max1;
		else f1 = max2; ca>0 ca 0 f1 = max1 f1 max1 f1 = max2 f1 max2 if(cb>0)f2 = max3;
		else f2 = max4; cb>0 cb 0 f2 = max3 f2 max3 f2 = max4 f2 max4 int cf = f1.compareTo(f2); cf f1.compareTo(f2) f1.compareTo f1 f2 if(cf>0)System.out.println(f1);
		else System.out.println(f2); cf>0 cf 0 System.out.println(f1) System.out.println System.out System System.out f1 System.out.println(f2) System.out.println System.out System System.out f2 String args[] args

import java.util.Scanner;
import java.math.BigInteger;


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

		int a,b,c,d;
		a = b = c = d = 0;

		if(input.hasNextInt())a = input.nextInt();
		if(input.hasNextInt())b = input.nextInt();	
		if(input.hasNextInt())c = input.nextInt();
		if(input.hasNextInt())d = input.nextInt();


		BigInteger A = BigInteger.valueOf(a);
		BigInteger B = BigInteger.valueOf(b);
		BigInteger max1 = A.multiply(BigInteger.valueOf(c));
		BigInteger max2 = A.multiply(BigInteger.valueOf(d));
		BigInteger max3 = B.multiply(BigInteger.valueOf(c));
		BigInteger max4 = B.multiply(BigInteger.valueOf(d));

		int ca = max1.compareTo(max2);
		int cb = max3.compareTo(max4);

		BigInteger f1,f2;
		if(ca>0)f1 = max1;
		else f1 = max2;
		if(cb>0)f2 = max3;
		else f2 = max4;

		int cf = f1.compareTo(f2);
		if(cf>0)System.out.println(f1);
		else System.out.println(f2);


		
	}
}