#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; int main() { vector > p(3); for(int i=0; i<3; ++i) cin >> p[i].first >> p[i].second; sort(p.begin(), p.end()); do{ int dx = p[1].first - p[0].first; int dy = p[1].second - p[0].second; if(p[2].first - p[1].first == dy && p[2].second - p[1].second == -dx){ int x = p[2].first - dx; int y = p[2].second - dy; cout << x << ' ' << y << endl; return 0; } }while(next_permutation(p.begin(), p.end())); cout << -1 << endl; return 0; }