#include<iostream>
#include<cstdio>
using namespace std;
int main(){
	double a,b,c,d,e,f;
	while(cin>>a>>b>>c>>d>>e>>f){
		a*=d;
		b*=d;
		c*=d;
		d*=a;
		e*=a;
		f*=a;
		if(a==d){
			a-=d;
			b-=e;
			c-=f;
		}else{
			a+=d;
			b+=e;
			c+=f;
		}
		c/=b;
		e*=c;
		f-=e;
		f/=d;
		printf("%.3f %.3f\n",f,c);
	}
}