import java.util.Scanner;

public class B_Help_Vasilisa_The_Wise2 {
	public static void main(String[] args){
		Scanner input=new Scanner(System.in);
		@SuppressWarnings("unused")
		int r1=input.nextInt(),r2=input.nextInt();
		int c1=input.nextInt(),c2=input.nextInt();
		@SuppressWarnings("unused")
		int d1=input.nextInt(),d2=input.nextInt();
		int a,b,c,d;
		a=(r1-c2+d1)/2;
		b=(r1+c2-d1)/2;
		c=(2*c1-r1+c2-d1)/2;
		d=(c2-r1+d1)/2;
		System.out.println(a+" "+b);
		System.out.println(c+" "+d);
	}
}
