#include <cmath>
#include <iostream>

struct TPoint
{
    double x;
    double y;
    TPoint(){}
    TPoint(int X, int Y)
     : x(X), y(Y){}
};
struct TTriangle
{
    TPoint p1;
    TPoint p2;
    TPoint p3;
};
typedef TPoint TVector;
TVector Vector(const TPoint& A, const TPoint& B)
{
    return TVector(B.x - A.x, B.y - A.y);
    // return TVector(A.x - B.x, A.y - B.y);
}
double Cross(const TVector& A, const TVector& B)
{
    return A.x * B.y - B.x * A.y;
}

bool IsContain(const TTriangle& Tri, const TPoint& P)
{
    bool s1 = Cross(Vector(Tri.p1, Tri.p2), Vector(Tri.p2, P)) < 0;
    bool s2 = Cross(Vector(Tri.p2, Tri.p3), Vector(Tri.p3, P)) < 0;
    bool s3 = Cross(Vector(Tri.p3, Tri.p1), Vector(Tri.p1, P)) < 0;
    // std::cout << s1 << s2 << s3 << std::endl;
    return s1 == s2 && s2 == s3;
}
int main()
{
    while(true){
        TTriangle Tri;
        TPoint P;
        std::cin >> Tri.p1.x >> Tri.p1.y >> Tri.p2.x >> Tri.p2.y >> Tri.p3.x >> Tri.p3.y >> P.x >> P.y;
        if(std::cin.eof()) break;
        std::cout << (IsContain(Tri, P) ? "YES" : "NO") << std::endl;
    }
    return 0;
}