#include <iostream>
using namespace std;
bool judge_Cross(float, float,float,float);

int main() {
	float x1, y1, x2, y2, x3, y3, xp, yp;
	while (cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3 >> xp >> yp) {
		float pax = x1 - xp;
		float pay = y1 - yp;
		float pbx = x2 - xp;
		float pby = y2 - yp;
		float pcx = x3 - xp;
		float pcy = y3 - yp;

		if ((judge_Cross(pax, pay, pbx, pay) && judge_Cross(pbx, pby, pcx, pcy) && judge_Cross(pcx, pcy, pax, pay)) ||
			!((judge_Cross(pax, pay, pbx, pay) || judge_Cross(pbx, pby, pcx, pcy) || judge_Cross(pcx, pcy, pax, pay)))) {
			cout << "YES" << endl;
		} else {
			cout << "NO" << endl;
		}
	}

	return 0;
}

bool judge_Cross(float x1,float y1,float x2,float y2) {
	if (x1 * y2 - x2 * y1 > 0) {
		return true;
	} else {
		return false;
	}
}