import java.util.Scanner;
import java.util.Queue;
import java.util.ArrayDeque;
import java.util.Arrays;
 
public class Main {
	static int cnt = 0;
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		long a = sc.nextInt();
		long b = sc.nextInt();
		long c = sc.nextInt();
		long d = sc.nextInt();
		long max = -1000000000000000000l;
		long ac = a*c;
		long bc = b*c;
		long cd = b*d;
		long da =d* a;
		System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da)));
		
	}

} import java.util.Scanner; Scanner java.util import java.util.Queue; Queue java.util import java.util.ArrayDeque; ArrayDeque java.util import java.util.Arrays; Arrays java.util public class Main {
	static int cnt = 0;
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		long a = sc.nextInt();
		long b = sc.nextInt();
		long c = sc.nextInt();
		long d = sc.nextInt();
		long max = -1000000000000000000l;
		long ac = a*c;
		long bc = b*c;
		long cd = b*d;
		long da =d* a;
		System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da)));
		
	}

} Main static int cnt = 0; cnt 0 public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		long a = sc.nextInt();
		long b = sc.nextInt();
		long c = sc.nextInt();
		long d = sc.nextInt();
		long max = -1000000000000000000l;
		long ac = a*c;
		long bc = b*c;
		long cd = b*d;
		long da =d* a;
		System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da)));
		
	} main {
		Scanner sc = new Scanner(System.in);
		
		long a = sc.nextInt();
		long b = sc.nextInt();
		long c = sc.nextInt();
		long d = sc.nextInt();
		long max = -1000000000000000000l;
		long ac = a*c;
		long bc = b*c;
		long cd = b*d;
		long da =d* a;
		System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da)));
		
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) long a = sc.nextInt(); a sc.nextInt() sc.nextInt sc long b = sc.nextInt(); b sc.nextInt() sc.nextInt sc long c = sc.nextInt(); c sc.nextInt() sc.nextInt sc long d = sc.nextInt(); d sc.nextInt() sc.nextInt sc long max = -1000000000000000000l; max -1000000000000000000l 1000000000000000000l long ac = a*c; ac a*c a c long bc = b*c; bc b*c b c long cd = b*d; cd b*d b d long da =d* a; da d* a d a System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da))) System.out.println System.out System System.out Math.max(Math.max(ac, bc), Math.max(cd, da)) Math.max Math Math.max(ac, bc) Math.max Math ac bc Math.max(cd, da) Math.max Math cd da String[] args args public class Main {
	static int cnt = 0;
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		long a = sc.nextInt();
		long b = sc.nextInt();
		long c = sc.nextInt();
		long d = sc.nextInt();
		long max = -1000000000000000000l;
		long ac = a*c;
		long bc = b*c;
		long cd = b*d;
		long da =d* a;
		System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da)));
		
	}

} public class Main {
	static int cnt = 0;
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		long a = sc.nextInt();
		long b = sc.nextInt();
		long c = sc.nextInt();
		long d = sc.nextInt();
		long max = -1000000000000000000l;
		long ac = a*c;
		long bc = b*c;
		long cd = b*d;
		long da =d* a;
		System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da)));
		
	}

} Main
import java.util.Scanner;
import java.util.Queue;
import java.util.ArrayDeque;
import java.util.Arrays;
 
public class Main {
	static int cnt = 0;
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		long a = sc.nextInt();
		long b = sc.nextInt();
		long c = sc.nextInt();
		long d = sc.nextInt();
		long max = -1000000000000000000l;
		long ac = a*c;
		long bc = b*c;
		long cd = b*d;
		long da =d* a;
		System.out.println(Math.max(Math.max(ac, bc), Math.max(cd, da)));
		
	}

}