#include <iostream>
#include <string>
#include <cmath>
using namespace std;
const string mes[2] = {"YES", "NO"};
double dist(double a, double b) {
  return sqrt(a*a + b*b);
}

int main (int argc, char const* argv[]) {
  double x1, y1, x2, y2, x3, y3, xp, yp;
  while (cin>>x1>>y1>>x2>>y2>>x3>>y3>>xp>>yp) {
    double cx = (x1 + x2 + x3) / 3.0;
    double cy = (y1 + y2 + y3) / 3.0;
    double cdist = dist(cx-x1,cy-y1) + dist(cx-x2,cy-y2) + dist(cx-x3,cy-y3);
    //double cdist = dist(x1-x2,y1-y2) + dist(x1-x3,y1-y3);
    double pdist = dist(xp-x1,yp-y1) + dist(xp-x3,yp-y2) + dist(xp-x3,yp-y3);
    int res = (cdist > pdist)?0:1;
    cout<<mes[res]<<endl;
  }
  
  return 0;
}