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