#include <iostream>
#include <complex>
#include <vector>
#include <cmath>
using namespace std;

int sign(float n){
	if(n < 0)return -1;
	else if(n > 0)return 1;
	return 0;
}

float angle(float ax, float ay, float bx, float by, float cx, float cy){
    //angle between ab and ac
    float ab = atan2(by-ay,bx-ax);
    float ac = atan2(cy-ay,cx-ax);
    if(ab < 0)ab += 2*M_PI;
    if(ac < 0)ac += 2*M_PI;
    float ang = ac - ab;
    return (fabs(ang) < M_PI ? ang : -sign(ang) * 2 * M_PI + ang) * 180 / M_PI;
}

bool isPointInPolygon(complex< float > a, vector< complex< float > > p){
	int n = p.size();
	float sum = 0;
	
	for(int i = 0; i < n; ++i){
		sum += angle(a.real(), a.imag(), p[i].real(), p[i].imag(), p[(i+1)%n].real(), p[(i+1)%n].imag());
	}
	
	if(sum >= 300){ //if sum is 360
		return true;
	}
	return false; //if sum is 0
}

int main(){
	float x1, y1, x2, y2, x3, y3 , xp, yp;
	vector< complex< float > > triangle;
	complex< float > point;
	
	while(cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3 >> xp >> yp){
		point = complex< float >(xp, yp);
		triangle.push_back(complex< float >(x1, y1));
		triangle.push_back(complex< float >(x2, y2));
		triangle.push_back(complex< float >(x3, y3));
		
		if(isPointInPolygon(point, triangle))
			cout << "YES" << endl;
		else
			cout << "NO" << endl;
	}
}