Go: package main

import (
	"bufio"
	"fmt"
	"math"
	"os"
	"strconv"
)

var sc = bufio.NewScanner(os.Stdin)
var out = bufio.NewWriter(os.Stdout)

func main() {
	sc.Split(bufio.ScanWords)
	defer out.Flush()
	for {
		data := nextInts(6)
		fmt.Printf("%.3f\n", Round(GetX(data[0], data[1], data[2], data[3], data[4], data[5]), 3))
		fmt.Printf("%.3f\n", Round(GetY(data[0], data[1], data[2], data[3], data[4], data[5]), 3))
	}
}

func GetX(a, b, c, d, e, f float64) float64 {
	return float64(((c * e) - (b * f)) / ((a * e) - (b * d)))
}

func GetY(a, b, c, d, e, f float64) float64 {
	return float64(((c * d) - (a * f)) / ((b * d) - (a * e)))
}

func Round(f float64, places int) float64 {
	shift := math.Pow(10, float64(places))
	return math.Floor(f*shift+.5) / shift
}

func next() string {
	sc.Scan()
	return sc.Text()
}

func nextInt() float64 {
	a, _ := strconv.Atoi(next())
	return float64(a)
}

func nextInts(n int) []float64 {
	a := make([]float64, n)
	for i := 0; i < n; i++ {
		a[i] = nextInt()
	}
	return a
}

Python: while True:
    try:
        a,b,c,d,e,f = map(float,input().split(" "))
        x,y = 0,0
        float(x)
        float(y)
        x = (e*c-b*f) / (a*e-b*d)
        y = ((-(d*c)+a*f) / (a*e-b*d))
        print("%.3f" %(x), end="")
        print(" ", end="")
        print("%.3f" %(y))
    except:
        break

Python: while True:
    try:
        a, b, c, d, e, f = map(int, raw_input().split()) 
        x = float(c*e - b*f)/(a*e - b*d)
        y = float(c*d - a*f)/(b*d - a*e)
        print ("%.3f %.3f" % (round(x,-4), round(y,-4)))
    except:
        break

Python: while True:
    try:
        a,b,c,d,e,f = map(int, input().split())
        x = (c*e - b*f)/(a*e - b*d)
        y = (a*f - c*d)/(a*e - b*d)
        print(x, y)
    except EOFError : break

Python: import sys

for line in sys.stdin:
    (a, b, c, d, e, f) = [float(i) for i in line.split()]
    det = a * e - b * d
    x = (e * c - b * f) / det
    y = (-d * c + a * f) / det
    print("%0.3f %0.3f" % (x, y))

Python: def jisuan(lis):
    ns = lis.split(" ")
    for i in range(6):
        ns[i] = float(ns[i])
    a, b, c, d, e, f = ns[0], ns[1], ns[2], ns[3], ns[4], ns[5]
    x = (c * e - b * f) / (a * e - b * d)
    y = (c * d - a * f) / (b * d - a * e)
    return [x, y]


inpu = str(input())
nums = inpu.split("\n")
for l in range(len(nums)):
    k0 = jisuan("1 2 3 4 5 6")[0]
    k1 = jisuan("1 2 3 4 5 6")[1]
    print("%.3f" % k0, "%.3f" % k1)

Python: (a,b,c,d,e,f)  =  map(int,input().split())
g = (a * e)  - (b * d)
ans1= "{0:.3f}".format((( e * c) + ( -b * f)) / g)
ans2= "{0:.3f}".format(((-d * c) + (  a * f)) / g)
(a,b,c,d,e,f)  =  map(int,input().split())
g = (a * e)  - (b * d)
ans3= "{0:.3f}".format((( e * c) + ( -b * f)) / g)
ans4= "{0:.3f}".format(((-d * c) + (  a * f)) / g)
print (ans1,ans2)
print (ans3,ans4)

Python: while True:
    try:
        a, b, c, d, e, f = map(float, raw_input().split()) 
        x = (c*e - b*f)/(a*e - b*d)
        y = (c*d - a*f)/(b*d - a*e)
        x = round(1000*x)/1000
        y = round(1000*y)/1000
        print ("%.3f %.3f" % (x, y))
    except:
        break

Python: import math
import sys

while True:
	try:
		a,b,c,d,e,f = map(float, input().split())
		if a*e == b*d:
			continue
		x = (c*e - b*f)/(a*e - b*d)
		y = (c*d - a*f)/(b*d - a*e)
		print('{0:.3f} {1:.3f}'.format(x,y)) 
	except EOFError:
		break

Python: def function(a,b,c,d,e,f):
    y = (c - a*f/d)/(b - a*e/d)
    x = (c - b*y)/a
    print('{:.3f}'.format(float(x)), '{:.3f}'.format(float(y)))

while True:
    try:
        a,b,c,d,e,f = list(map(int,input().split()))
        a,b,c,d,e,f = int(a),int(b),int(c),int (d),int(e),int(f)
        function(a,b,c,d,e,f)
    except EOFError:
        break

Python: import numpy

Python: # ????????£???????¨????????§£???????????°??????
# ax + by = c
# dx + ey = f
import sys

def inverse(a, b, d, e):
    deta = a * e - b * d
    return (deta, e, -b, -d, a)

while True:
    data = sys.stdin.readline()
    if data is None or data.strip() == '':
        break
    data = data.strip().split(' ')
    a, b, c, d, e, f = [float(i) for i in data]

    inv = inverse(a, b, d, e)
    x = (inv[1] * c + inv[2] * f) / inv[0]
    y = (inv[3] * c + inv[4] * f) / inv[0]

    print('%.4f %.4f' % (x, y))

Python: import sys
from decimal import Decimal
from fractions import Fraction

def main():

    input_strings = sys.stdin.readlines()
    for matrix_string in input_strings:
        matrix = list(map(Fraction, list(matrix_string.split())))
        if matrix[0] == 0:
            matrix = matrix[3:] + matrix[:3]
        matrix = list(map(lambda x: x / matrix[0], matrix[:3])) + matrix[3:]
        matrix = matrix[:3] + list(map(lambda x: x[1] - matrix[3] * x[0], zip(matrix[:3], matrix[3:])))
        matrix = matrix[:3] + list(map(lambda x: x / matrix[4], matrix[3:]))
        matrix = list(map(lambda x: x[0] - matrix[1] * x[1], zip(matrix[:3], matrix[3:]))) + matrix[3:]
        matrix = list(map(float, matrix))
        matrix = list(map(Decimal, matrix))
        matrix = list(map(lambda x: x.quantize(Decimal('.001'), rounding='ROUND_HALF_UP'), matrix))

        print('%.3f %.3f' % (matrix[2], matrix[5]))
main()

Python: while(True):
    try:
        a,b,c,d,e,f= map(float,input().split(" "))
        det=a*e-b*d
        if(det!=0):
            x=(c*e-b*f)/det
            y=(a*f-c*d)/det
        print("{:.3f} {:.3f)".format(x+0,y+0))
    except:
        break

Python: while True:
    try:
        a, b, c, d, e, f = map(int, input().split())
    except:
        break
    y = (c * d - f * a) / (b * d - e * a)
    x = (c - (b * y)) / a
    print("{:.3f} {:.3f}".format(x, y))

Python: import sys
for line in sys.stdin:
    a,b,c,d,e,f = map(int, line.split())
    y = (c/a - f/d)/(b/a - e/d)
    x = -(e/d) * y + (f/d)
    print("%.3f %.3f" % (x, y))

Python: def getX(value):
	numerator = value[2] * value[4] - value[1] * value[5]
	denominator = value[0] * value[4] - value[1] * value[3]
	return numerator / denominator

def getY(value):
	numerator = value[2] * value[3] - value[0] * value[5]
	denominator = value[1] * value[3] - value[0] * value[4]
	return numerator / denominator

while True:
	try:
		value = []
		for i in input().split(" "):
			value.append(int(i))
		x = getX(value)
		y = getY(value)
		print('%.3f %.3f'%(round(x, 3),round(y, 3)))
	except EOFError:
		break

Python: import sys

for line in sys.stdin:
    a, b, c, d, e, f = map(int, line.split())
    y = (a * f - d * c) / (a * e - b * d)
    x = (c * e - b * f) / (a * e - b * d)
    if x == 0:        x = abs(x)
    if y == 0:        x = abs(y)       
    print('{:.3f} {:.3f}'.format(x, y))

Python: import sys
for line in sys.stdin:
    a, b, c, d, e, f = map(float, line.split())
    print('{:.3f} {:.3f}'.format((c*e - b*f) / (a*e - b*d), (a*f - c*d) / (a*e - b*d)))

Python: # -*-coding:utf-8

import numpy as np

def main():

    tokens = raw_input().split(' ')

    for i in range(6):
        tokens[i] = int(tokens[i])

    A = np.array([[tokens[0],tokens[1]] ,[tokens[3],tokens[4]]])
    B = np.array([tokens[2],tokens[5]])

    X = np.linalg.solve(A, B)

    for i in range(2):
        if X[i] == -0.000:
            X[i] = abs(X[i])

    print( '%.3f %0.3f' % (X[0], X[1]) )

    return 0

if __name__ == '__main__':
    for i in range(2):
        main()

Python: z = []
while True:
	try:
		a, b, c, d, e, f = map(float, raw_input().split())
		x = (c * e - b * f) / (a * e - d * b)
		y = (c * d - f * a) / (b * d - e * a)
		z.append([x, y])
	
	except:
		break
for i in z:
	print("{:.3f} {:.3f}".format(i[0] + 0, i[1] + 0))

Python: while True:
    try:
        a,b,c,d,e,f = map(int, input().split())
    except EOFError:
        break
    x = c/a - (b/a) * (a*f-c*d) / (a*e-b*d)
    y = (f*a - c*d) / (e*a - b*d)
    print('{:.3f} {:.3f}'.format(x, y))

Python: while True:
    try:
        a, b, c, d, e, f = map(float, input().split())
    except:
        break
    y = (c*d-f*a) / (b*d-e*a)
    x = (c - b*y) / a
    print(x, y)