import java.io.FileNotFoundException;
import java.math.BigInteger;
import java.util.Arrays;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) throws FileNotFoundException {

		//    	File file = new File("src/in.txt");
		//    	Scanner sc = new Scanner(file);

		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int d = sc.nextInt();


		BigInteger[] ans = new BigInteger[4];
		ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c));
		ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d));
		ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c));
		ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d));
		Arrays.sort(ans);
		System.out.println(ans[3]);

	}
} import java.io.FileNotFoundException; FileNotFoundException java.io import java.math.BigInteger; BigInteger java.math import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) throws FileNotFoundException {

		//    	File file = new File("src/in.txt");
		//    	Scanner sc = new Scanner(file);

		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int d = sc.nextInt();


		BigInteger[] ans = new BigInteger[4];
		ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c));
		ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d));
		ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c));
		ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d));
		Arrays.sort(ans);
		System.out.println(ans[3]);

	}
} Main public static void main(String[] args) throws FileNotFoundException {

		//    	File file = new File("src/in.txt");
		//    	Scanner sc = new Scanner(file);

		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int d = sc.nextInt();


		BigInteger[] ans = new BigInteger[4];
		ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c));
		ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d));
		ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c));
		ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d));
		Arrays.sort(ans);
		System.out.println(ans[3]);

	} main {

		//    	File file = new File("src/in.txt");
		//    	Scanner sc = new Scanner(file);

		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int d = sc.nextInt();


		BigInteger[] ans = new BigInteger[4];
		ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c));
		ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d));
		ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c));
		ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d));
		Arrays.sort(ans);
		System.out.println(ans[3]);

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc int c = sc.nextInt(); c sc.nextInt() sc.nextInt sc int d = sc.nextInt(); d sc.nextInt() sc.nextInt sc BigInteger[] ans = new BigInteger[4]; ans new BigInteger[4] 4 ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c)) ans[0] ans 0 BigInteger.valueOf(a).multiply(BigInteger.valueOf(c)) BigInteger.valueOf(a).multiply BigInteger.valueOf(a) BigInteger.valueOf BigInteger a BigInteger.valueOf(c) BigInteger.valueOf BigInteger c ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d)) ans[1] ans 1 BigInteger.valueOf(a).multiply(BigInteger.valueOf(d)) BigInteger.valueOf(a).multiply BigInteger.valueOf(a) BigInteger.valueOf BigInteger a BigInteger.valueOf(d) BigInteger.valueOf BigInteger d ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c)) ans[2] ans 2 BigInteger.valueOf(b).multiply(BigInteger.valueOf(c)) BigInteger.valueOf(b).multiply BigInteger.valueOf(b) BigInteger.valueOf BigInteger b BigInteger.valueOf(c) BigInteger.valueOf BigInteger c ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d)) ans[3] ans 3 BigInteger.valueOf(b).multiply(BigInteger.valueOf(d)) BigInteger.valueOf(b).multiply BigInteger.valueOf(b) BigInteger.valueOf BigInteger b BigInteger.valueOf(d) BigInteger.valueOf BigInteger d Arrays.sort(ans) Arrays.sort Arrays ans System.out.println(ans[3]) System.out.println System.out System System.out ans[3] ans 3 String[] args args public class Main {
	public static void main(String[] args) throws FileNotFoundException {

		//    	File file = new File("src/in.txt");
		//    	Scanner sc = new Scanner(file);

		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int d = sc.nextInt();


		BigInteger[] ans = new BigInteger[4];
		ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c));
		ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d));
		ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c));
		ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d));
		Arrays.sort(ans);
		System.out.println(ans[3]);

	}
} public class Main {
	public static void main(String[] args) throws FileNotFoundException {

		//    	File file = new File("src/in.txt");
		//    	Scanner sc = new Scanner(file);

		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int d = sc.nextInt();


		BigInteger[] ans = new BigInteger[4];
		ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c));
		ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d));
		ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c));
		ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d));
		Arrays.sort(ans);
		System.out.println(ans[3]);

	}
} Main
import java.io.FileNotFoundException;
import java.math.BigInteger;
import java.util.Arrays;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) throws FileNotFoundException {

		//    	File file = new File("src/in.txt");
		//    	Scanner sc = new Scanner(file);

		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int d = sc.nextInt();


		BigInteger[] ans = new BigInteger[4];
		ans[0] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(c));
		ans[1] = BigInteger.valueOf(a).multiply(BigInteger.valueOf(d));
		ans[2] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(c));
		ans[3] = BigInteger.valueOf(b).multiply(BigInteger.valueOf(d));
		Arrays.sort(ans);
		System.out.println(ans[3]);

	}
}