#include <algorithm>
#include <iostream>

using namespace std;

struct Vector
{
public:
	double x;
	double y;

public:
	inline Vector()
	{

	}
	
	inline Vector(const int& x, const int& y) :
		x(x),
		y(y)
	{

	}
};

istream& operator>>(std::istream& stream, Vector& vector)
{
	stream >> vector.x >> vector.y;
	return stream;
}

struct Segment
{
public:
	Vector begin;
	Vector end;

public:
	inline Segment(const Vector& begin, const Vector& end) :
		begin(begin.x, begin.y),
		end  (end  .x, end  .y)
	{

	}
};

bool isLeft(Segment segment, Vector point)
{
	return (segment.end.x - segment.begin.x)*(point.y - segment.begin.y) - (segment.end.y - segment.begin.y) * (point.x - segment.begin.x) > 0;
}

int main()
{
	Vector A, B, C, P;
	while(cin >> A >> B >> C >> P)
	{
		if( isLeft(Segment(A, B), P) && isLeft(Segment(B, C), P) && isLeft(Segment(C, A), P) )
			cout << "YES" << endl;
		else
			cout << "NO" << endl;
	}

	return 0;
}