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