#include <iostream>
using namespace std;

int main() {
	double x1, y1, x2, y2, x3, y3, xp, yp;

	while (cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3 >> xp >> yp) {
		if (
			(
					(x1 < xp && xp < x2 || x2 < xp && xp < x1)
				&&	(y1 < yp && yp < y2 || y2 < yp && yp < y1)
			) || (
					(x2 < xp && xp < x3 || x3 < xp && xp < x2)
				&&	(y2 < yp && yp < y3 || y3 < yp && yp < y2)
			) || (
					(x3 < xp && xp < x1 || x1 < xp && xp < x3)
				&&	(y3 < yp && yp < y1 || y1 < yp && yp < y3)
			)
		) {
			cout << "YES" << endl;
		} else {
			cout << "NO" << endl;
		}
	}

	return 0;
}