#include using namespace std; #define rep(i,n) for(int i = 0; i < (n);i++) #define sz(x) int(x.size()) typedef long long ll; typedef long double ld; typedef pair P; constexpr int INF = 1e9; int main() { ld a, b, c, d, e, f; cin >> a >> b >> c >> d >> e >> f; ld y = 0, x = 0; y = d * (f - c) / (a * c - d * b); x = (c - b * y) / a; printf("%.12Lf %.12Lf\n", x , y); return 0; }