#include using namespace std; #define int long long #define rep(i,n) for(int i=0;i<(n);i++) #define pb push_back #define all(v) (v).begin(),(v).end() #define fi first #define se second typedef vectorvint; typedef pairpint; typedef vectorvpint; templateinline void chmin(A &a,B b){if(a>b)a=b;} templateinline void chmax(A &a,B b){if(auku(){ vint ret(3); rep(i,3)cin>>ret[i]; return ret; } vint cross(vint A,vint B,vint C){ rep(i,3){ B[i]-=A[i]; C[i]-=A[i]; } return {B[1]*C[2]-B[2]*C[1],B[2]*C[0]-B[0]*C[2],B[0]*C[1]-B[1]*C[0]}; } int dot(vint A,vint B){ int ret=0; rep(i,3)ret+=A[i]*B[i]; return ret; } signed main(){ vint A,B,C,D; A=uku();B=uku();C=uku();D=uku(); vint X,Y,Z,W; X=cross(A,B,D); Y=cross(B,C,D); Z=cross(C,A,D); W=cross(A,B,C); vint latte; latte.pb(dot(X,W)); latte.pb(dot(Y,W)); latte.pb(dot(Z,W)); sort(all(latte)); if(latte[0]>0||latte[2]<0)cout<<"YES"<