import java.util.Scanner;


public class Main {


	public static void main(String[] args)  {
		Scanner sc = new Scanner(System.in);
		Long a = Long.parseLong(sc.next());
		Long b = Long.parseLong(sc.next());
		Long c = Long.parseLong(sc.next());
		Long d = Long.parseLong(sc.next());
		
		Long max = -1000000000000000000l;
		
		max = Math.max(max,a * c);
		max = Math.max(max,a * d);
		max = Math.max(max,b * c);
		max = Math.max(max,b * d);
		System.out.println(max);
	}
} import java.util.Scanner; Scanner java.util public class Main {


	public static void main(String[] args)  {
		Scanner sc = new Scanner(System.in);
		Long a = Long.parseLong(sc.next());
		Long b = Long.parseLong(sc.next());
		Long c = Long.parseLong(sc.next());
		Long d = Long.parseLong(sc.next());
		
		Long max = -1000000000000000000l;
		
		max = Math.max(max,a * c);
		max = Math.max(max,a * d);
		max = Math.max(max,b * c);
		max = Math.max(max,b * d);
		System.out.println(max);
	}
} Main public static void main(String[] args)  {
		Scanner sc = new Scanner(System.in);
		Long a = Long.parseLong(sc.next());
		Long b = Long.parseLong(sc.next());
		Long c = Long.parseLong(sc.next());
		Long d = Long.parseLong(sc.next());
		
		Long max = -1000000000000000000l;
		
		max = Math.max(max,a * c);
		max = Math.max(max,a * d);
		max = Math.max(max,b * c);
		max = Math.max(max,b * d);
		System.out.println(max);
	} main {
		Scanner sc = new Scanner(System.in);
		Long a = Long.parseLong(sc.next());
		Long b = Long.parseLong(sc.next());
		Long c = Long.parseLong(sc.next());
		Long d = Long.parseLong(sc.next());
		
		Long max = -1000000000000000000l;
		
		max = Math.max(max,a * c);
		max = Math.max(max,a * d);
		max = Math.max(max,b * c);
		max = Math.max(max,b * d);
		System.out.println(max);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) Long a = Long.parseLong(sc.next()); a Long.parseLong(sc.next()) Long.parseLong Long sc.next() sc.next sc Long b = Long.parseLong(sc.next()); b Long.parseLong(sc.next()) Long.parseLong Long sc.next() sc.next sc Long c = Long.parseLong(sc.next()); c Long.parseLong(sc.next()) Long.parseLong Long sc.next() sc.next sc Long d = Long.parseLong(sc.next()); d Long.parseLong(sc.next()) Long.parseLong Long sc.next() sc.next sc Long max = -1000000000000000000l; max -1000000000000000000l 1000000000000000000l max = Math.max(max,a * c) max Math.max(max,a * c) Math.max Math max a * c a c max = Math.max(max,a * d) max Math.max(max,a * d) Math.max Math max a * d a d max = Math.max(max,b * c) max Math.max(max,b * c) Math.max Math max b * c b c max = Math.max(max,b * d) max Math.max(max,b * d) Math.max Math max b * d b d 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 sc = new Scanner(System.in);
		Long a = Long.parseLong(sc.next());
		Long b = Long.parseLong(sc.next());
		Long c = Long.parseLong(sc.next());
		Long d = Long.parseLong(sc.next());
		
		Long max = -1000000000000000000l;
		
		max = Math.max(max,a * c);
		max = Math.max(max,a * d);
		max = Math.max(max,b * c);
		max = Math.max(max,b * d);
		System.out.println(max);
	}
} public class Main {


	public static void main(String[] args)  {
		Scanner sc = new Scanner(System.in);
		Long a = Long.parseLong(sc.next());
		Long b = Long.parseLong(sc.next());
		Long c = Long.parseLong(sc.next());
		Long d = Long.parseLong(sc.next());
		
		Long max = -1000000000000000000l;
		
		max = Math.max(max,a * c);
		max = Math.max(max,a * d);
		max = Math.max(max,b * c);
		max = Math.max(max,b * d);
		System.out.println(max);
	}
} Main
import java.util.Scanner;


public class Main {


	public static void main(String[] args)  {
		Scanner sc = new Scanner(System.in);
		Long a = Long.parseLong(sc.next());
		Long b = Long.parseLong(sc.next());
		Long c = Long.parseLong(sc.next());
		Long d = Long.parseLong(sc.next());
		
		Long max = -1000000000000000000l;
		
		max = Math.max(max,a * c);
		max = Math.max(max,a * d);
		max = Math.max(max,b * c);
		max = Math.max(max,b * d);
		System.out.println(max);
	}
}
