#include<cstdio>
#include<iostream>
#include<cmath>
#include<complex>
#include<string>
#include<map>
using namespace std;
typedef complex<double> xy_t;
double x[4],y[4];

int main(){

  while(true){
    for(int i=0;i<4;i++) cin >> x[i] >> y[i];
    if(!cin) break;
    xy_t a(x[0],y[0]),b(x[1],y[1]),c(x[2],y[2]),p(x[3],y[3]);
    double pab=(conj(a-p)*(b-p)).imag();
    double pbc=(conj(b-p)*(c-p)).imag();
    double pca=(conj(c-p)*(a-p)).imag();
    bool ok= (pab>0 && pbc>0 && pca>0) || (pab<0 && pbc<0 && pca<0);
    cout << (ok ? "YES" : "NO") << endl;
  }


  return 0;

}