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