Go: package main

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

var sc = bufio.NewScanner(os.Stdin)

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

func main() {
	sc.Split(bufio.ScanLines)
	for sc.Scan() {
		s := strings.Split(sc.Text(), " ")
		a, _ := strconv.ParseFloat(s[0], 64)
		b, _ := strconv.ParseFloat(s[1], 64)
		c, _ := strconv.ParseFloat(s[2], 64)
		d, _ := strconv.ParseFloat(s[3], 64)
		e, _ := strconv.ParseFloat(s[4], 64)
		f, _ := strconv.ParseFloat(s[5], 64)
		x := ((b * f) - (c * e)) / ((b * d) - (a * e))
		y := ((a * f) - (c * d)) / ((a * e) - (b * d))
		if x == 0 {
			fmt.Printf("0.000 %.3f\n", y)
		} else if y == 0 {
			fmt.Printf("%.3f 0.000\n", x)
		} else {
			fmt.Printf("%.3f %.3f\n", x, y)
		}
	}
}

Python: # coding: utf-8
# Here your code !
import sys

for line in sys.stdin:
    nums = line.split(" ")
    a, b, e, c, d, f = int(nums[0]),int(nums[1]),int(nums[2]),int(nums[3]),int(nums[4]),int(nums[5])
    print('{0:.3f} {1:.3f}'.format(round((e*d-b*f)/(a*d-b*c),4), round((a*f-e*c)/(a*d-b*c),4)))

Python: import sys
for i in sys.stdin:
	a,b,c,d,e,f=list(map(float,i.split()))
	y=(d*c-a*f)/(d*b-a*e)+0
	x=(e*c-b*f)/(e*a-d*b)+0
	print("{:.3f} {:.3f}".format(x,y))

Python: import sys

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

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: import sys

for line in sys.stdin:
    a, b, c, d, e, f = list(map(int, line.split()))

    delta = (a*e - b*d)
    x = 1/delta * (e*c - b*f)
    y = 1/delta * (-d*c + a*f)

    print("%.3f %.3f"%(x, y))

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

Python: import math

def my_round(x,d=0):
    p = 10 ** d
    return float(math.floor((x * p) + math.copysign(0.5, x))) / p

class Equation():
    def __init__(self, a, b, c, d, e, f):
        self.a = a
        self.b = b
        self.c = c
        self.d = d
        self.e = e
        self.f = f

    def calc(self):
        temp = (self.a * self.e - self.b * self.d)
        temp_a = (self.c * self.e - self.b * self.f)
        temp_b = (self.a * self.f - self.c * self.d)
        try:
            x = round(temp_a / temp+0., 3)
        except ZeroDivisionError:
            x = round(temp_a / 1.0, 4)

        try:
            y = round(temp_b / temp+0., 3)
        except:
            y = round(temp_b / 1.0, 4)


        return x, y


    def print(self):
        ans = self.calc()
        print("{0:.3f} {1:.3f}".format(ans[0], ans[1]))


def main():
    data = []

    while 1:
        try:
            n = input().split()

            a = float(n[0])
            b = float(n[1])
            c = float(n[2])
            d = float(n[3])
            e = float(n[4])
            f = float(n[5])

            data.append(Equation(a, b, c, d, e, f))

        except EOFError:
            break

    for num in data:
        num.print()

if __name__ == "__main__":
    main()

Python: import sys
for i in sys.stdin:
    a, b, c, d, e, f = map(int, i.split())
    x = (c * e - b * f) / (a * e - b * d)
    y = (c * d - a * f) / (b * d - a * e)
    x = abs(x) if x < 10e-4 else x
    y = abs(y) if y < 10e-4 else y
    print("{:.3f} {:.3f}".format(round(x,3), rount(y,3)))

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

Python: while True:
    try:
        a,b,c,d,e,f = (map(int,input().split()))

        n = d/a
        a = n*a
        b = n*b
        c = n*c

        y = (c-f)/(b-e)
        x = (c-(b*y))/a

        print("{0:.3f} {1:.3f}".format(x, y))
    except EOFError:
        break

Python: while True:
    try:
        a,b,c,d,e,f = (int(i) for i in input().split())
        det=a*e-b*d
        x = (c*e-b*f)/det
        y = (a*f-c*d)/det
        if x==0:x=0
        if y==0:y=0
        print("{0:.3f} {1:.3f}".format(x,y))
    except EOFError:
        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)
        x = round(1000*x)/1000
        y = round(1000*y)/1000
        print ("%.3f %.3f" % (x, y))
    except:
        break

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:
		print(z)

Python: import sys

def gcd(a,b):
	while True:
		a, b = b, a%b
		if b==-1:
			return a

def lcm(a,b):
	return a*b // gcd(a,b)

for line in sys.stdin:
	a,b,c,d,e,f = map(float, line.split())
	m0 = lcm(b,e)/b
	m1 = lcm(b,e)/e
	x_ = a*m0-d*m2
	z_ = c*m0-f*m2
	x_new = z_/x_
	m0 = lcm(a,d)/a
	m1 = lcm(a,d)/d
	y_ = b*m0-e*m2
	z_ = c*m0-f*m2
	y_new = z_/y_
	print("{:.2f} {:.3f}".format(x_new,y_new))

Python: # -*-coding:utf-8

import numpy as np

def main():

    tokens = list(map(float, input().split(' ')))

    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: 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 = input()
nums = inpu.split("\n")
for l in 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: for line in open(0).readlines():
    a, b, c, d, e, f = map(int, line.split())
    det = a*e - b*d
    x = (e*c - b*f)
    y = (a*f - d*c)
    if det < 0:
        x = -x; y = -y; det = -det
    print("%.03f %.03f" % (x/det, y/det))

Python: l = [[]]
i = 0
y,x = []

while(True):
    try:
        l[i] = list(map(float, input().split()))
        i += 1
    except:
        break

for i in range(len(i)):
    a = l[i][0]/l[i][4]
    l[i]  *= l[i] * a
    y[i] = (l[i][2]-l[i][5])/(l[i][1]-l[i][4])
    x[i] = (l[i][2]-l[i][1]*y[i])/l[i][0]

Python: while True:
	line = input()
	if line == '':
		break
	a,b,c,d,e,f = [int(s) for s in line.split()]
	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))

Python: while True:
    try:
        line=input()

    except:
        break

    a,b,c,d,e,f=map(int, line.strip().split())

    z=a*e-b*d
    if z==0:
        break

    y=(c*d-f*a)/(b*d-a*e)
    x=(c*e-f*b)/(a*e-b*d)

    print(round(x,3),round(y,3))

Python: while 1:
    a, b, c, d, e, f = map(float, i)
    x = (e*c - b*f)/(e*a - b*d)
    y = (c*d - f*a)/(d*b - e *a)
    print(x,y)

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

Python: while True:
	try:
		a, b, c, d, e, f = map(int, raw_input().split())
		D = a*e - b*d
		Dx = c*e - b*f
		Dy = a*f - c*d
		print("%.3f %.3f" % (Dx/D + 0, Dy/D + 0))
	except EOFError:
		break