#include<iostream>
typedef float f;f a,b,c,d,h,i,e,g;int r(f k,f l,f m,f n){m-=k;n-=l;k=e-k;l=g-l;return m*l-n*k?m*l-n*k>0?1:-1:0;}int main(){for(;!(std::cin>>a>>b>>c>>d>>h>>i>>e>>g).eof();)std::cout<<(r(a,b,c,d)==r(c,d,h,i)==r(h,i,a,b)?"YES\n":"NO\n");}