#include #include #include #include #include #include #include #include #include #include static const int MOD = 1000000007; using ll = int64_t; using u32 = uint32_t; using namespace std; template constexpr T INF = ::numeric_limits::max()/32*15+208; template struct Point: public pair { T x = this->first; T y = this->second; explicit Point(T x = 0,T y = 0): pair(x, y) {}; }; int main() { vector> v(3); for (int i = 0; i < 3; ++i) { int a, b; scanf("%d %d",&a, &b); v[i] = Point(a, b); } sort(v.begin(), v.end()); do { if((v[1].x-v[0].x)*(v[2].x-v[1].x) != (v[0].y-v[1].y)*(v[2].y-v[1].y)) continue; if((v[1].x-v[0].x)*(v[1].x-v[0].x)+(v[1].y-v[0].y)*(v[1].y-v[0].y) != (v[2].x-v[1].x)*(v[2].x-v[1].x)+(v[2].y-v[1].y)*(v[2].y-v[1].y)) continue; cout << v[0].x + v[2].x-v[1].x << " " << v[0].y + v[2].y - v[1].y << "\n"; return 0; }while(next_permutation(v.begin(), v.end())); puts("-1"); return 0; }