import java.util.Scanner;

public class Main {
	public static void main(String args[]) {
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextInt();
		long b = stdIn.nextInt();
		long c = stdIn.nextInt();
		long d = stdIn.nextInt();
		
		System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
	}
} 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.nextInt();
		long b = stdIn.nextInt();
		long c = stdIn.nextInt();
		long d = stdIn.nextInt();
		
		System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
	}
} Main public static void main(String args[]) {
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextInt();
		long b = stdIn.nextInt();
		long c = stdIn.nextInt();
		long d = stdIn.nextInt();
		
		System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
	} main {
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextInt();
		long b = stdIn.nextInt();
		long c = stdIn.nextInt();
		long d = stdIn.nextInt();
		
		System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
	} Scanner stdIn = new Scanner(System.in); stdIn new Scanner(System.in) long a = stdIn.nextInt(); a stdIn.nextInt() stdIn.nextInt stdIn long b = stdIn.nextInt(); b stdIn.nextInt() stdIn.nextInt stdIn long c = stdIn.nextInt(); c stdIn.nextInt() stdIn.nextInt stdIn long d = stdIn.nextInt(); d stdIn.nextInt() stdIn.nextInt stdIn System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d)))) System.out.println System.out System System.out Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))) Math.max Math a * c a c Math.max(a * d, Math.max(b * c, b * d)) Math.max Math a * d a d Math.max(b * c, b * d) Math.max Math b * c b c b * d b d String args[] args public class Main {
	public static void main(String args[]) {
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextInt();
		long b = stdIn.nextInt();
		long c = stdIn.nextInt();
		long d = stdIn.nextInt();
		
		System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
	}
} public class Main {
	public static void main(String args[]) {
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextInt();
		long b = stdIn.nextInt();
		long c = stdIn.nextInt();
		long d = stdIn.nextInt();
		
		System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String args[]) {
		Scanner stdIn = new Scanner(System.in);
		long a = stdIn.nextInt();
		long b = stdIn.nextInt();
		long c = stdIn.nextInt();
		long d = stdIn.nextInt();
		
		System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
	}
}