#include <iostream>
#include <complex>
#include <cmath>
using namespace std;
typedef complex<double> xy_t;

// ??????: a.x*b.x
double dot_product(xy_t a, xy_t b) { 
  return (conj(a)*b).real(); 
}
// ??????: a.x*b.y - b.x*a.y
// ????§???¢????¬????????????¢????????????
double cross_product(xy_t a, xy_t b) { 
  return (conj(a)*b).imag(); 
}
// ?????±: ????????¨ p ??????????????´?????? b ????????±
xy_t projection(xy_t p, xy_t b) { 
  return b*dot_product(p,b)/norm(b); 
}

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]);
  // pab ????¬????????????¢?????? 2 ??????,cross product(a-p,b-p)
  // pbc ????¬????????????¢?????? 2 ??????,cross product(b-p,c-p)
  // pca ????¬????????????¢?????? 2 ??????,cross product(c-p,a-p)
  int aaa = 0;
  if (cross_product(a-p,b-p) > 0) aaa++;
  if (cross_product(b-p,c-p) > 0) aaa++;
  if (cross_product(c-p,a-p) > 0) aaa++;
  bool ok = false;
  if (aaa == 3 || aaa == 0) ok = true;
  cout << (ok ? "YES" : "NO") <<  endl;
  }
}