import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		long a = scan.nextLong();
		long b = scan.nextLong();
		long c = scan.nextLong();
		long d = scan.nextLong();
		scan.close();



		long max1 =a*c;
		long max2 =a*d;

		long max3 =b*c;
		long max4 =b*d;

		long max = Math.max(Math.max(max1,max2),Math.max(max3, max4));

		System.out.println(max);
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		long a = scan.nextLong();
		long b = scan.nextLong();
		long c = scan.nextLong();
		long d = scan.nextLong();
		scan.close();



		long max1 =a*c;
		long max2 =a*d;

		long max3 =b*c;
		long max4 =b*d;

		long max = Math.max(Math.max(max1,max2),Math.max(max3, max4));

		System.out.println(max);
	}
} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		long a = scan.nextLong();
		long b = scan.nextLong();
		long c = scan.nextLong();
		long d = scan.nextLong();
		scan.close();



		long max1 =a*c;
		long max2 =a*d;

		long max3 =b*c;
		long max4 =b*d;

		long max = Math.max(Math.max(max1,max2),Math.max(max3, max4));

		System.out.println(max);
	} main {
		Scanner scan = new Scanner(System.in);
		long a = scan.nextLong();
		long b = scan.nextLong();
		long c = scan.nextLong();
		long d = scan.nextLong();
		scan.close();



		long max1 =a*c;
		long max2 =a*d;

		long max3 =b*c;
		long max4 =b*d;

		long max = Math.max(Math.max(max1,max2),Math.max(max3, max4));

		System.out.println(max);
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) long a = scan.nextLong(); a scan.nextLong() scan.nextLong scan long b = scan.nextLong(); b scan.nextLong() scan.nextLong scan long c = scan.nextLong(); c scan.nextLong() scan.nextLong scan long d = scan.nextLong(); d scan.nextLong() scan.nextLong scan scan.close() scan.close scan long max1 =a*c; max1 a*c a c long max2 =a*d; max2 a*d a d long max3 =b*c; max3 b*c b c long max4 =b*d; max4 b*d b d long max = Math.max(Math.max(max1,max2),Math.max(max3, max4)); max Math.max(Math.max(max1,max2),Math.max(max3, max4)) Math.max Math Math.max(max1,max2) Math.max Math max1 max2 Math.max(max3, max4) Math.max Math max3 max4 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 scan = new Scanner(System.in);
		long a = scan.nextLong();
		long b = scan.nextLong();
		long c = scan.nextLong();
		long d = scan.nextLong();
		scan.close();



		long max1 =a*c;
		long max2 =a*d;

		long max3 =b*c;
		long max4 =b*d;

		long max = Math.max(Math.max(max1,max2),Math.max(max3, max4));

		System.out.println(max);
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		long a = scan.nextLong();
		long b = scan.nextLong();
		long c = scan.nextLong();
		long d = scan.nextLong();
		scan.close();



		long max1 =a*c;
		long max2 =a*d;

		long max3 =b*c;
		long max4 =b*d;

		long max = Math.max(Math.max(max1,max2),Math.max(max3, max4));

		System.out.println(max);
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		long a = scan.nextLong();
		long b = scan.nextLong();
		long c = scan.nextLong();
		long d = scan.nextLong();
		scan.close();



		long max1 =a*c;
		long max2 =a*d;

		long max3 =b*c;
		long max4 =b*d;

		long max = Math.max(Math.max(max1,max2),Math.max(max3, max4));

		System.out.println(max);
	}
}