#include using namespace std; typedef long long ll; typedef pair P; #define REP(i,n) for(int i=0;i> T; while(T--){ ll x1,y1,x2,y2,X1,Y1,X2,Y2; cin >> x1 >> y1 >> x2 >> y2 >> X1 >> Y1 >> X2 >> Y2; if((y2-y1)*(X2-X1)!=(x2-x1)*(Y2-Y1)){ cout << "No" << endl; continue; } if((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2)<(X1-X2)*(X1-X2)+(Y1-Y2)*(Y1-Y2)){ cout << "No" << endl; continue; } cout << "Yes" << endl; } return 0; }