#include using namespace std; int main(){ ios_base::sync_with_stdio(false); cin.tie(nullptr); vector> XY(3); for(auto &[x,y] : XY) cin >> x >> y; for(int i=0; i<3; i++){ auto [x,y] = XY.at(i); int x0 = -1000,y0,x1,y1; for(int k=0; k<3; k++){ if(i == k) continue; if(x0 == -1000) tie(x0,y0) = XY.at(k); else tie(x1,y1) = XY.at(k); } x0 -= x,y0 -= y,x1 -= x,y1 -= y; if(x0*x1 == -y0*y1 && x0*x0+y0*y0 == x1*x1+y1*y1){ x0 += x1,y0 += y1; cout << x0+x << " " << y0+y << "\n"; return 0; } } cout << "-1\n"; }