	#include <cstdio>
	#include <iostream>
	#include <math.h>

	using namespace std;
	#define rep(i,n) for(int i = 0; i < (n); ++i)

	bool judge(double x[2], double y[2]) {
		double cross = x[0] * y[1] - y[0] * x[1];
		if(cross >= 0) return true;
		else return false;
	}

	int main() {
		double x1, y1, x2, y2, x3, y3, xp, yp;
		while(scanf("%f %f %f %f %f %f %f %f", &x1, &y1, &x2, &y2, &x3, &y3, &xp, &yp) != EOF) {
			double x[2], y[2];
			x[0] = x2 - x1;
			y[0] = y2 - y1; 
			x[1] = xp - x1;
			y[1] = yp - y1;
			if(!judge(x, y)) {
				cout << "NO" << endl;
				continue;
			}
			x[0] = x3 - x2;
			y[0] = y3 - y2;
			x[1] = xp - x2;
			y[1] = yp - y2;
			if(!judge(x, y)) {
				cout << "NO" << endl;
				continue;
			}
			x[0] = x1 - x3;
			y[0] = y1 - y3;
			x[1] = xp - x3;
			y[1] = yp - y3;
			if(!judge(x, y)) {
				cout << "NO" << endl;
				continue;
			}
			cout << "YES" << endl;
		}
		return 0;
	}