#include<iostream>
#define rep(i,a) for(int i=0;i<(a);i++)

using namespace std;

long double calc(double x1,double y1,double x2,double y2,double x,double y){
	return (x1-x2)*(y-y1)+(y1-y2)*(x1-x);
}

bool isCross(double x1,double y1,double x2,double y2,double x3,double y3,double x4,double y4){
	if( calc(x1,y1,x2,y2,x3,y3) * calc(x1,y1,x2,y2,x4,y4)<0 )
		if( calc(x3,y3,x4,y4,x1,y1) * calc(x3,y3,x4,y4,x2,y2)<0 )
			return true;
	return false;
} 


int main(){
	while(1){
		double x[3],y[3],xp,yp;

		rep(i,3)cin>>x[i]>>y[i];
		if(!(cin>>xp>>yp))break;

		bool cross=false;
		rep(i,3){
			if( isCross(x[i%3],y[i%3],x[(i+1)%3],y[(i+1)%3],x[(i+2)%3],y[(i+2)%3],xp,yp) )
				cross=true;
		}
		if(cross==true){
			cout<<"NO"<<endl;
		}else{
			cout<<"YES"<<endl;
		}
	}
	return 0;
}