#include <iostream>

double cross(double ax, double ay, double bx, double by)
{
    return ax*by - ay*bx;
}

int main()
{
    std::ios::sync_with_stdio(false);
    std::cin.tie(0);

    /* A(x1, y1)
     * B(x2, y2)
     * C(x3, y3)
     * P(xp, yp)
     * */
    double x1,y1,x2,y2,x3,y3,xp,yp;
    while (std::cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3 >> xp >> yp) {
        if (cross(x2-x1, y2-y1, xp-x1, yp-y1) > 0 &&
            cross(x3-x2, y3-y2, xp-x2, yp-y2) > 0 &&
            cross(x1-x3, y1-y3, xp-x3, yp-y3) > 0)
            std::cout << "YES" << std::endl;
        else
            std::cout << "NO" << std::endl;
    }
}

