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