a,b,c,d,e,f = map(int,input().split()) x = (f-e*c/b)/(d-e*a/b) #x = f*(1-c)/(d-e*c/b) y = (c-a*x)/b print(x,y)