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

int edinton(int i,int j, int k);
double cross(double *a,double *b);

int main(){
    double p[4][3],z[3];
    int sum=0;
    for(int l=0;l<4;l++){
        cin >> p[l][0] >> p[l][1];
        p[l][2]=0;
    }
    for(int i=0;i<3;i++){
        z[i]=cross(p[i],p[3]);
        z[i]=z[i]/fabs(z[i]);
        sum+=z[i];
    }
    if(sum==3) cout << "YES" << endl;
    else cout << "NO" << endl;
    return 0;
}

int edinton(int i,int j, int k){
    int a=1,b=2,c=3,d;
    for(int l=0;l<3;l++){
        if(i==a&&j==b&&k==c) return 1;
        d=c;c=b;b=a;a=d;
    }
    a=3; b=2; c=1;
    for(int l=0;l<3;l++){
        if(i==a&&j==b&&k==c) return -1;
        d=c;c=b;b=a;a=d;
    }
    return 0;
}
double cross(double *a,double *b){
    double c=0;
    for(int i=1;i<=3;i++)
        for(int j=1;j<=3;j++)
            for(int k=1;k<=3;k++){
                c+=edinton(i, j, k)*a[j]*b[k];
            }
    return c;
}