import java.io.BufferedReader;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.PriorityQueue;
import java.util.StringTokenizer;

public class Main {
	static Scanner sc;
	static PrintWriter out;
	static ArrayList<Edge> adj[];
	static int V,E;
	static int[] dist;
	static int[] parent;
	static final int oo = (int) 1e9;
	public static void main(String[] args) throws Exception {
		// TODO Auto-generated method stub
		sc = new Scanner(System.in);
		out = new PrintWriter(System.out);
		int a,b,c,d;
		a = sc.nextInt();
		b = sc.nextInt();
		c = sc.nextInt();
		d = sc.nextInt();
		long c1 = 1l*a*c;
		long c2 = 1l*a*d;
		long c3 = 1l*b*c;
		long c4 = 1l*b*d;
		out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4))));
		out.close();
	}
	static void dijkstra(int src) {
		dist = new int[V];
		Arrays.fill(dist, oo);
		parent = new int[V];
		Arrays.fill(parent, -1);
		dist[src] = 0;
		PriorityQueue<Edge> pq = new PriorityQueue<>();
		pq.add(new Edge(src,0));
		while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		}
//		return -1;
	}
	static class Edge extends java.awt.Point implements Comparable<Edge>{		
		public Edge(int u, int val) {
			// TODO Auto-generated constructor stub
			super(u, val);
		}

		@Override
		public int compareTo(Edge e) {
			// TODO Auto-generated method stub
			return y - e.y;
		}		
	}
	static class Scanner{
		BufferedReader br;
		StringTokenizer st;
		public Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(in));
		}
		private String next() throws Exception{
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}
		public int nextInt() throws Exception{
			return Integer.parseInt(next());
		}
		public long nextLong() throws Exception{
			return Long.parseLong(next());
		}
		public double nextDouble() throws Exception{
			return Double.parseDouble(next());
		}
		public String nextLine() throws Exception {
			return br.readLine();
		}

	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStream; InputStream java.io import java.io.InputStreamReader; InputStreamReader java.io import java.io.PrintWriter; PrintWriter java.io import java.util.ArrayList; ArrayList java.util import java.util.Arrays; Arrays java.util import java.util.PriorityQueue; PriorityQueue java.util import java.util.StringTokenizer; StringTokenizer java.util public class Main {
	static Scanner sc;
	static PrintWriter out;
	static ArrayList<Edge> adj[];
	static int V,E;
	static int[] dist;
	static int[] parent;
	static final int oo = (int) 1e9;
	public static void main(String[] args) throws Exception {
		// TODO Auto-generated method stub
		sc = new Scanner(System.in);
		out = new PrintWriter(System.out);
		int a,b,c,d;
		a = sc.nextInt();
		b = sc.nextInt();
		c = sc.nextInt();
		d = sc.nextInt();
		long c1 = 1l*a*c;
		long c2 = 1l*a*d;
		long c3 = 1l*b*c;
		long c4 = 1l*b*d;
		out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4))));
		out.close();
	}
	static void dijkstra(int src) {
		dist = new int[V];
		Arrays.fill(dist, oo);
		parent = new int[V];
		Arrays.fill(parent, -1);
		dist[src] = 0;
		PriorityQueue<Edge> pq = new PriorityQueue<>();
		pq.add(new Edge(src,0));
		while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		}
//		return -1;
	}
	static class Edge extends java.awt.Point implements Comparable<Edge>{		
		public Edge(int u, int val) {
			// TODO Auto-generated constructor stub
			super(u, val);
		}

		@Override
		public int compareTo(Edge e) {
			// TODO Auto-generated method stub
			return y - e.y;
		}		
	}
	static class Scanner{
		BufferedReader br;
		StringTokenizer st;
		public Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(in));
		}
		private String next() throws Exception{
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}
		public int nextInt() throws Exception{
			return Integer.parseInt(next());
		}
		public long nextLong() throws Exception{
			return Long.parseLong(next());
		}
		public double nextDouble() throws Exception{
			return Double.parseDouble(next());
		}
		public String nextLine() throws Exception {
			return br.readLine();
		}

	}
} Main static Scanner sc; sc static PrintWriter out; out static ArrayList<Edge> adj[]; adj static int V V E; E static int[] dist; dist static int[] parent; parent static final int oo = (int) 1e9; oo (int) 1e9 public static void main(String[] args) throws Exception {
		// TODO Auto-generated method stub
		sc = new Scanner(System.in);
		out = new PrintWriter(System.out);
		int a,b,c,d;
		a = sc.nextInt();
		b = sc.nextInt();
		c = sc.nextInt();
		d = sc.nextInt();
		long c1 = 1l*a*c;
		long c2 = 1l*a*d;
		long c3 = 1l*b*c;
		long c4 = 1l*b*d;
		out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4))));
		out.close();
	} main {
		// TODO Auto-generated method stub
		sc = new Scanner(System.in);
		out = new PrintWriter(System.out);
		int a,b,c,d;
		a = sc.nextInt();
		b = sc.nextInt();
		c = sc.nextInt();
		d = sc.nextInt();
		long c1 = 1l*a*c;
		long c2 = 1l*a*d;
		long c3 = 1l*b*c;
		long c4 = 1l*b*d;
		out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4))));
		out.close();
	} sc = new Scanner(System.in) sc new Scanner(System.in) out = new PrintWriter(System.out) out new PrintWriter(System.out) int a a b b c c d; d a = sc.nextInt() a sc.nextInt() sc.nextInt sc b = sc.nextInt() b sc.nextInt() sc.nextInt sc c = sc.nextInt() c sc.nextInt() sc.nextInt sc d = sc.nextInt() d sc.nextInt() sc.nextInt sc long c1 = 1l*a*c; c1 1l*a*c 1l*a*c 1l a c long c2 = 1l*a*d; c2 1l*a*d 1l*a*d 1l a d long c3 = 1l*b*c; c3 1l*b*c 1l*b*c 1l b c long c4 = 1l*b*d; c4 1l*b*d 1l*b*d 1l b d out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4)))) out.println out Math.max(c1, Math.max(c2, Math.max(c3, c4))) Math.max Math c1 Math.max(c2, Math.max(c3, c4)) Math.max Math c2 Math.max(c3, c4) Math.max Math c3 c4 out.close() out.close out String[] args args static void dijkstra(int src) {
		dist = new int[V];
		Arrays.fill(dist, oo);
		parent = new int[V];
		Arrays.fill(parent, -1);
		dist[src] = 0;
		PriorityQueue<Edge> pq = new PriorityQueue<>();
		pq.add(new Edge(src,0));
		while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		}
//		return -1;
	} dijkstra {
		dist = new int[V];
		Arrays.fill(dist, oo);
		parent = new int[V];
		Arrays.fill(parent, -1);
		dist[src] = 0;
		PriorityQueue<Edge> pq = new PriorityQueue<>();
		pq.add(new Edge(src,0));
		while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		}
//		return -1;
	} dist = new int[V] dist new int[V] V Arrays.fill(dist, oo) Arrays.fill Arrays dist oo parent = new int[V] parent new int[V] V Arrays.fill(parent, -1) Arrays.fill Arrays parent -1 1 dist[src] = 0 dist[src] dist src 0 PriorityQueue<Edge> pq = new PriorityQueue<>(); pq new PriorityQueue<>() pq.add(new Edge(src,0)) pq.add pq new Edge(src,0) while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		} !pq.isEmpty() pq.isEmpty() pq.isEmpty pq {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		} Edge e = pq.poll(); e pq.poll() pq.poll pq if(dist[e.x] < e.y)
				continue; dist[e.x] < e.y dist[e.x] dist e.x e e.x e.y e e.y continue; for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			} Edge e2 adj[e.x] adj e.x e e.x {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			} {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			} if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				} dist[e2.x] > e2.y+e.y dist[e2.x] dist e2.x e2 e2.x e2.y+e.y e2.y e2 e2.y e.y e e.y {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				} pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y)) pq.add pq new Edge(e2.x,dist[e2.x] = e2.y+e.y) parent[e2.x] = e.x parent[e2.x] parent e2.x e2 e2.x e.x e e.x int src src static class Edge extends java.awt.Point implements Comparable<Edge>{		
		public Edge(int u, int val) {
			// TODO Auto-generated constructor stub
			super(u, val);
		}

		@Override
		public int compareTo(Edge e) {
			// TODO Auto-generated method stub
			return y - e.y;
		}		
	} Edge public Edge(int u, int val) {
			// TODO Auto-generated constructor stub
			super(u, val);
		} Edge {
			// TODO Auto-generated constructor stub
			super(u, val);
		} super(u, val) super u val int u u int val val @Override
		public int compareTo(Edge e) {
			// TODO Auto-generated method stub
			return y - e.y;
		} compareTo {
			// TODO Auto-generated method stub
			return y - e.y;
		} return y - e.y; y - e.y y e.y e e.y Edge e e Point Comparable static class Scanner{
		BufferedReader br;
		StringTokenizer st;
		public Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(in));
		}
		private String next() throws Exception{
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}
		public int nextInt() throws Exception{
			return Integer.parseInt(next());
		}
		public long nextLong() throws Exception{
			return Long.parseLong(next());
		}
		public double nextDouble() throws Exception{
			return Double.parseDouble(next());
		}
		public String nextLine() throws Exception {
			return br.readLine();
		}

	} Scanner BufferedReader br; br StringTokenizer st; st public Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(in));
		} Scanner {
			br = new BufferedReader(new InputStreamReader(in));
		} br = new BufferedReader(new InputStreamReader(in)) br new BufferedReader(new InputStreamReader(in)) InputStream in in private String next() throws Exception{
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		} next {
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		} while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine()); st == null || !st.hasMoreTokens() st == null st null !st.hasMoreTokens() st.hasMoreTokens() st.hasMoreTokens st st = new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) return st.nextToken(); st.nextToken() st.nextToken st public int nextInt() throws Exception{
			return Integer.parseInt(next());
		} nextInt {
			return Integer.parseInt(next());
		} return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next public long nextLong() throws Exception{
			return Long.parseLong(next());
		} nextLong {
			return Long.parseLong(next());
		} return Long.parseLong(next()); Long.parseLong(next()) Long.parseLong Long next() next public double nextDouble() throws Exception{
			return Double.parseDouble(next());
		} nextDouble {
			return Double.parseDouble(next());
		} return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next public String nextLine() throws Exception {
			return br.readLine();
		} nextLine {
			return br.readLine();
		} return br.readLine(); br.readLine() br.readLine br public class Main {
	static Scanner sc;
	static PrintWriter out;
	static ArrayList<Edge> adj[];
	static int V,E;
	static int[] dist;
	static int[] parent;
	static final int oo = (int) 1e9;
	public static void main(String[] args) throws Exception {
		// TODO Auto-generated method stub
		sc = new Scanner(System.in);
		out = new PrintWriter(System.out);
		int a,b,c,d;
		a = sc.nextInt();
		b = sc.nextInt();
		c = sc.nextInt();
		d = sc.nextInt();
		long c1 = 1l*a*c;
		long c2 = 1l*a*d;
		long c3 = 1l*b*c;
		long c4 = 1l*b*d;
		out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4))));
		out.close();
	}
	static void dijkstra(int src) {
		dist = new int[V];
		Arrays.fill(dist, oo);
		parent = new int[V];
		Arrays.fill(parent, -1);
		dist[src] = 0;
		PriorityQueue<Edge> pq = new PriorityQueue<>();
		pq.add(new Edge(src,0));
		while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		}
//		return -1;
	}
	static class Edge extends java.awt.Point implements Comparable<Edge>{		
		public Edge(int u, int val) {
			// TODO Auto-generated constructor stub
			super(u, val);
		}

		@Override
		public int compareTo(Edge e) {
			// TODO Auto-generated method stub
			return y - e.y;
		}		
	}
	static class Scanner{
		BufferedReader br;
		StringTokenizer st;
		public Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(in));
		}
		private String next() throws Exception{
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}
		public int nextInt() throws Exception{
			return Integer.parseInt(next());
		}
		public long nextLong() throws Exception{
			return Long.parseLong(next());
		}
		public double nextDouble() throws Exception{
			return Double.parseDouble(next());
		}
		public String nextLine() throws Exception {
			return br.readLine();
		}

	}
} public class Main {
	static Scanner sc;
	static PrintWriter out;
	static ArrayList<Edge> adj[];
	static int V,E;
	static int[] dist;
	static int[] parent;
	static final int oo = (int) 1e9;
	public static void main(String[] args) throws Exception {
		// TODO Auto-generated method stub
		sc = new Scanner(System.in);
		out = new PrintWriter(System.out);
		int a,b,c,d;
		a = sc.nextInt();
		b = sc.nextInt();
		c = sc.nextInt();
		d = sc.nextInt();
		long c1 = 1l*a*c;
		long c2 = 1l*a*d;
		long c3 = 1l*b*c;
		long c4 = 1l*b*d;
		out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4))));
		out.close();
	}
	static void dijkstra(int src) {
		dist = new int[V];
		Arrays.fill(dist, oo);
		parent = new int[V];
		Arrays.fill(parent, -1);
		dist[src] = 0;
		PriorityQueue<Edge> pq = new PriorityQueue<>();
		pq.add(new Edge(src,0));
		while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		}
//		return -1;
	}
	static class Edge extends java.awt.Point implements Comparable<Edge>{		
		public Edge(int u, int val) {
			// TODO Auto-generated constructor stub
			super(u, val);
		}

		@Override
		public int compareTo(Edge e) {
			// TODO Auto-generated method stub
			return y - e.y;
		}		
	}
	static class Scanner{
		BufferedReader br;
		StringTokenizer st;
		public Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(in));
		}
		private String next() throws Exception{
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}
		public int nextInt() throws Exception{
			return Integer.parseInt(next());
		}
		public long nextLong() throws Exception{
			return Long.parseLong(next());
		}
		public double nextDouble() throws Exception{
			return Double.parseDouble(next());
		}
		public String nextLine() throws Exception {
			return br.readLine();
		}

	}
} Main
import java.io.BufferedReader;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.PriorityQueue;
import java.util.StringTokenizer;

public class Main {
	static Scanner sc;
	static PrintWriter out;
	static ArrayList<Edge> adj[];
	static int V,E;
	static int[] dist;
	static int[] parent;
	static final int oo = (int) 1e9;
	public static void main(String[] args) throws Exception {
		// TODO Auto-generated method stub
		sc = new Scanner(System.in);
		out = new PrintWriter(System.out);
		int a,b,c,d;
		a = sc.nextInt();
		b = sc.nextInt();
		c = sc.nextInt();
		d = sc.nextInt();
		long c1 = 1l*a*c;
		long c2 = 1l*a*d;
		long c3 = 1l*b*c;
		long c4 = 1l*b*d;
		out.println(Math.max(c1, Math.max(c2, Math.max(c3, c4))));
		out.close();
	}
	static void dijkstra(int src) {
		dist = new int[V];
		Arrays.fill(dist, oo);
		parent = new int[V];
		Arrays.fill(parent, -1);
		dist[src] = 0;
		PriorityQueue<Edge> pq = new PriorityQueue<>();
		pq.add(new Edge(src,0));
		while(!pq.isEmpty()) {
			Edge e = pq.poll();
			if(dist[e.x] < e.y)
				continue;
//			if(e.x == dest)
//				return e.y;
			for(Edge e2:adj[e.x]) {
				if(dist[e2.x] > e2.y+e.y) {
					pq.add(new Edge(e2.x,dist[e2.x] = e2.y+e.y));
					parent[e2.x] = e.x;
				}
			}
		}
//		return -1;
	}
	static class Edge extends java.awt.Point implements Comparable<Edge>{		
		public Edge(int u, int val) {
			// TODO Auto-generated constructor stub
			super(u, val);
		}

		@Override
		public int compareTo(Edge e) {
			// TODO Auto-generated method stub
			return y - e.y;
		}		
	}
	static class Scanner{
		BufferedReader br;
		StringTokenizer st;
		public Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(in));
		}
		private String next() throws Exception{
			while(st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}
		public int nextInt() throws Exception{
			return Integer.parseInt(next());
		}
		public long nextLong() throws Exception{
			return Long.parseLong(next());
		}
		public double nextDouble() throws Exception{
			return Double.parseDouble(next());
		}
		public String nextLine() throws Exception {
			return br.readLine();
		}

	}
}
