#include <bits/stdc++.h>
using namespace std;

double x[4], y[4];

double l(int a, int b)
{
	return sqrt((y[a] - y[b]) * (y[a] - y[b]) + (x[a] - x[b]) * (x[a] - x[b]));
}

double T(int a, int b, int c)
{
	double A = l(a, b);
	double B = l(b, c);
	double C = l(c, a);
	double s = (A + B + C) / 2;
	return sqrt(s * (s - A) * (s - B) * (s - C));
}

int main()
{
	while (true){
		for (int i = 0; i < 4; i++){
			if (scanf("%lf %lf", &x[i], &y[i]) == EOF) return 0;
		}
		
		float S = T(0, 1, 3) + T(1, 2, 3) + T(2, 0, 3) - T(0, 1, 2);
		//printf("%f\n", S);
		if (S == 0){
			puts("YES");
		}
		else {
			puts("NO");
		}
	}
	
	return 0;
}