import std.container;
import std.range;
import std.algorithm;
import std.array;
import std.string;
import std.conv;
import std.stdio;
import std.container;

void main() {
	long a, b, c, d;
	readf("%s %s %s %s", &a, &b, &c, &d);

	long r = long.min;
	if (r < a * c) {
		r = a * c;
	}
	if (r < a * d) {
		r = a * d;
	}
	if (r < b * c) {
		r = b * c;
	}
	if (r < b * d) {
		r = b * d;
	}

	writeln(r);
}
