let _ =
  let round x =
    let eps = 0.0005 in
    let ux = if x > 0.0 then x else (-1.0) *. x in
    if ux < eps then 0.0 else x in
  try
    while true do
      let a, b, c, d, e, f = Scanf.scanf "%f %f %f %f %f %f\n" (fun a b c d e f -> (a,b,c,d,e,f)) in
      let dt = a *. e -. b *. d in
      let x = (c *. e -. b *. f) /. dt in
      let y = (a *. f -. c *. d) /. dt in
      Printf.printf "%.3f %.3f\n" (round x) (round y)
    done
  with
    End_of_file -> ()