import java.util.Scanner;

public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextLong();
		long b = stdIn.nextLong();
		long c = stdIn.nextLong();
		long d = stdIn.nextLong();
		long ans[] = new long[4];
		ans[0] = a*c;
		ans[1] = a*d;
		ans[2] = b*c;
		ans[3] = b*d;
		long max = ans[0];
		for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		}
		System.out.println(max);
		stdIn.close();
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextLong();
		long b = stdIn.nextLong();
		long c = stdIn.nextLong();
		long d = stdIn.nextLong();
		long ans[] = new long[4];
		ans[0] = a*c;
		ans[1] = a*d;
		ans[2] = b*c;
		ans[3] = b*d;
		long max = ans[0];
		for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		}
		System.out.println(max);
		stdIn.close();
	}
} Main public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextLong();
		long b = stdIn.nextLong();
		long c = stdIn.nextLong();
		long d = stdIn.nextLong();
		long ans[] = new long[4];
		ans[0] = a*c;
		ans[1] = a*d;
		ans[2] = b*c;
		ans[3] = b*d;
		long max = ans[0];
		for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		}
		System.out.println(max);
		stdIn.close();
	} main {
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextLong();
		long b = stdIn.nextLong();
		long c = stdIn.nextLong();
		long d = stdIn.nextLong();
		long ans[] = new long[4];
		ans[0] = a*c;
		ans[1] = a*d;
		ans[2] = b*c;
		ans[3] = b*d;
		long max = ans[0];
		for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		}
		System.out.println(max);
		stdIn.close();
	} Scanner stdIn = new Scanner(System.in); stdIn new Scanner(System.in) long a = stdIn.nextLong(); a stdIn.nextLong() stdIn.nextLong stdIn long b = stdIn.nextLong(); b stdIn.nextLong() stdIn.nextLong stdIn long c = stdIn.nextLong(); c stdIn.nextLong() stdIn.nextLong stdIn long d = stdIn.nextLong(); d stdIn.nextLong() stdIn.nextLong stdIn long ans[] = new long[4]; ans new long[4] 4 ans[0] = a*c ans[0] ans 0 a*c a c ans[1] = a*d ans[1] ans 1 a*d a d ans[2] = b*c ans[2] ans 2 b*c b c ans[3] = b*d ans[3] ans 3 b*d b d long max = ans[0]; max ans[0] ans 0 for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		} int i = 0; int i = 0; i 0 i < 4 i 4 i++ i++ i {
			if(max <= ans[i]){
				max = ans[i];
			}
		} {
			if(max <= ans[i]){
				max = ans[i];
			}
		} if(max <= ans[i]){
				max = ans[i];
			} max <= ans[i] max ans[i] ans i {
				max = ans[i];
			} max = ans[i] max ans[i] ans i System.out.println(max) System.out.println System.out System System.out max stdIn.close() stdIn.close stdIn String[] args args public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextLong();
		long b = stdIn.nextLong();
		long c = stdIn.nextLong();
		long d = stdIn.nextLong();
		long ans[] = new long[4];
		ans[0] = a*c;
		ans[1] = a*d;
		ans[2] = b*c;
		ans[3] = b*d;
		long max = ans[0];
		for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		}
		System.out.println(max);
		stdIn.close();
	}
} public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextLong();
		long b = stdIn.nextLong();
		long c = stdIn.nextLong();
		long d = stdIn.nextLong();
		long ans[] = new long[4];
		ans[0] = a*c;
		ans[1] = a*d;
		ans[2] = b*c;
		ans[3] = b*d;
		long max = ans[0];
		for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		}
		System.out.println(max);
		stdIn.close();
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextLong();
		long b = stdIn.nextLong();
		long c = stdIn.nextLong();
		long d = stdIn.nextLong();
		long ans[] = new long[4];
		ans[0] = a*c;
		ans[1] = a*d;
		ans[2] = b*c;
		ans[3] = b*d;
		long max = ans[0];
		for(int i = 0; i < 4; i++){
			if(max <= ans[i]){
				max = ans[i];
			}
		}
		System.out.println(max);
		stdIn.close();
	}
}