#include <stdio.h>
#include <math.h>

using namespace std;

//I can't understand, so I search the solution at http://oshiete.goo.ne.jp/qa/5729013.html

int main(){
	double x1,x2,x3,y1,y2,y3,xp,yp;
	double calc1,calc2,calc3;
	int count;

	while(scanf("%lf %lf %lf %lf %lf %lf %lf %lf",&x1,&y1,&x2,&y2,&x3,&y3,&xp,&yp)!=EOF){
		count=0;
		calc1 = (x1-xp)*(x2-xp)+(y1-yp)*(y2-yp);
		if(calc1 < 0)count++;
		calc2 = (x1-xp)*(x3-xp)+(y1-yp)*(y3-yp);
		if(calc2 < 0)count++;
		calc3 = (x3-xp)*(x2-xp)+(y3-yp)*(y2-yp);
		if(calc3 < 0)count++;

		if(count >= 2)printf("YES\n");
		else{
			printf("NO\n");
		}
	}
    return 0;
}