import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int []X = new int[3]; int []Y = new int[3]; for(int i = 0; i < 3; i++) { X[i] = scan.nextInt(); Y[i] = scan.nextInt(); } scan.close(); int ABx = X[1] - X[0]; int ABy = Y[1] - Y[0]; int ACx = X[2] - X[0]; int ACy = Y[2] - Y[0]; int BCx = X[2] - X[1]; int BCy = Y[2] - Y[1]; int lAB = norm(X[0], Y[0], X[1], Y[1]); int lAC = norm(X[0], Y[0], X[2], Y[2]); int lBC = norm(X[1], Y[1], X[2], Y[2]); if(lAB == lAC) { int k = ABx * ACx + ABy * ACy; if(k == 0) { int Mx = (X[1] + X[2]); int My = (Y[1] + Y[2]); int MAx = X[0] - Mx; int MAy = Y[0] - My; System.out.println(-MAx + " " + -MAy); }else { System.out.println(-1); } }else if(lAB == lBC) { int k = (-ABx) * BCx + (-ABy) * BCy; if(k == 0) { int Mx = (X[0] + X[2]); int My = (Y[0] + Y[2]); int MBx = X[1] - Mx; int MBy = Y[1] - My; System.out.println(-MBx + " " + -MBy); }else { System.out.println(-1); } }else if(lAC == lBC){ int k = (-ACx) * (-BCx) + (-ACy) * (-BCy); if(k == 0) { int Mx = (X[0] + X[1]); int My = (Y[0] + Y[1]); int MCx = X[2] - Mx; int MCy = Y[2] - My; System.out.println(-MCx + " " + -MCy); }else { System.out.println(-1); } }else { System.out.println(-1); } } public static int norm(int x1, int y1, int x2, int y2) { int l = (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2); return l; } }