import Text.Printf
main = getContents >>= mapM_ (fout . simultaneous_equation . fin) . lines
fin = map read . words
fout (x,y) = printf "%.3f %.3f\n" ((fromIntegral x)::Double) ((fromIntegral y)::Double)

simultaneous_equation [a,b,c,d,e,f]
 = head [(x,y) | x<-[-2000..2000], y<-[-2000..2000], a*x + b*y == c && d*x + e*y == f]