#include <iostream>
#include <cmath>
#include <algorithm>
using namespace std;

#define S(a) (a) * (a)

int main(void)
{
	double x1, x2, x3, y1, y2, y3, xp, yp;
	double a, b, c, ap, bp, cp;
	double as, bs, cs, ps;
	double A, B, C, P;
	double res;
	while (cin>>x1>>y1>>x2>>y2>>x3>>y3>>xp>>yp){
		a = sqrt(S(x1-x2) + S(y1-y2));
		b = sqrt(S(x3-x1) + S(y1-y3));
		c = sqrt(S(x3-x2) + S(y3-y2));
		ap = sqrt(S(x1-xp) + S(y1-yp));
		bp = sqrt(S(xp-x2) + S(yp-y2));
		cp = sqrt(S(x3-xp) + S(yp-y3));
		as = (a+ap+bp) / 2;
		bs = (c+bp+cp) / 2;
		cs = (b+ap+cp) / 2;
		ps = (a+b+c) / 2;
		A = sqrt(as * (as-a) * (as-ap) * (as-bp));
		B = sqrt(bs * (bs-c) * (bs-bp) * (bs-cp));
		C = sqrt(cs * (cs-b) * (cs-ap) * (cs-cp));
		P = sqrt(ps * (ps-a) * (ps-b) * (ps-c));
		if (sqrt(A+B+C-P) < 1e-9) cout << "YES" << endl;
		else cout << "NO" << endl;
	}
	
	return 0;
}