Go: package main

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

func gcd(num1, num2 int) int {
	if num2 == 0 {
		return num1
	}
	num3 := num1 % num2
	return gcd(num2, num3)
}

func lcm(num1, num2 int) int {
	if num1%num2 != 0 {
		num3 := gcd(num1, num2)
		for i := 1; ; i++ {
			check := num3 * i
			if check%num1 == 0 && check%num2 == 0 {
				return check
			}
		}
	} else {
		return num1
	}
}

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	for scanner.Scan() {
		strNums := strings.Fields(scanner.Text())
		nums := []int{}
		for _, strNum := range strNums {
			num, _ := strconv.Atoi(strNum)
			nums = append(nums, num)
		}
		a := nums[0]
		b := nums[1]
		c := nums[2]
		d := nums[3]
		e := nums[4]
		f := nums[5]
		lcm := lcm(a, d)
		mulA := lcm / a
		mulD := lcm / d
		a *= mulA
		b *= mulA
		c *= mulA
		d *= mulD
		e *= mulD
		f *= mulD

		if d < 0 {
			d *= -1
			e *= -1
			f *= -1
		}

		bE := b - e
		cF := c - f
		if bE==0{
		    bE=1
		}
		y := cF / bE
		x := (c - (y * b)) / a

		
			fmt.Printf("%d.000 ", x)
			fmt.Printf("%d.000\n", y)
	}
}

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

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

import sys
import math

r = sys.stdin.readlines()

r.pop(0)

n = [[float(i) for i in (j.split())] for j in r] #n is list of each lines
    
for l in n:
    print(l)
    y = (l[2]*l[3]-l[0]*l[5])/(l[1]*l[3]-l[0]*l[4])+0
    
    x = (l[2]*l[4]-l[5]*l[1])/(l[0]*l[4]-l[3]*l[1])+0
    
    print("{:.3f} {:.3f} ".format(x,y))

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

Python: EPS = 0.0001
while True:
    try:
        a = list(map(float, input().split()))
        dd = a[0]*a[4]-a[3]*a[1]
        d1 = a[2]*a[4]-a[5]*a[1]
        d2 = a[0]*a[5]-a[3]*a[2]
        print("{0:.3f} {1:.3f}".format(d1/dd+EPS, d2/dd+EPS))
    except EOFError:
        break

Python: while True:
    try:
        l=list(map(int, input().split()))
        x=(l[1]*l[5]-l[2]*l[4])/(l[1]*l[3]-l[0]*l[4])
        y=(l[2]-l[0]*x)/l[1]
        if x == 0: x = 0
        print( "{0:.3f} {1:.3f}".format(x,y))
    except:
        break

Python: while True:
	try:
		s=input().split()
	except:
		break
	a,b,c,d,e,f=int(s[0]),int(s[1]),int(s[2]),int(s[3]),int(s[4]),int(s[5])
	
	x=round((ce-bf)/(ae-db),3)
	y=round((cd-fa)/(bd-ea),3)
	print("%d %d",x,y)

Python: import sys

def inv(k):
    det = 1 / (k[0]*k[3] - k[1]*k[2])
    ret = [k[3] * det, -k[1] * det, -k[2] * det, k[0] * det]
    return ret

def dot(i, j):
    x = i[0] * j[0] + i[1] * j[1]
    y = i[2] * j[0] + i[3] * j[1]
    return [x,y]

def run():
    data = []
    for _data in sys.stdin:
        data.append(list(map(int, _data.split())))

    for _data in data:
        i = _data[:2] + _data[3:5]
        j = [_data[2],_data[5]]
        x, y = dot(inv(i), j)
        x, y = round(x, 3), round(y, 3)
        print('{0:.3f} {1:.3f}'.format(x,y))

if __name__ == '__main__':
    run()

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:
        break

Python: '''
ax + by = c
dx + ey = f

x = ( c - b * y ) / a
x = ( f - e * y ) / d
'''
while True:
	s = input().split()

	try:
		a = int(s[0])
		b = int(s[1])
		c = int(s[2])
		d = int(s[3])
		e = int(s[4])
		f = int(s[5])
	except:
		break

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

Python: [print("{0:.3f} {1:.3f}".format(
	(k[2] - k[1] * ((k[0] * k[5] - k[2] * k[3]) / (k[0] * k[4] - k[1] * k[3]))) / k[0],
	((k[0] * k[5] - k[2] * k[3]) / (k[0] * k[4] - k[1] * k[3])))
) for i in ["1 2 3 4 5 6", "2 -1 -2 -1 -1 -5"] for k in [[int(float(j)) for j in i.split()]]]

Python: x = []
y = []
while True:
    try:
        a, b, p, c, d, q = map(int, input().split())
        x.append((d*p-b*q)/(a*d-b*c))
        y.append((a*q-c*p)/(a*d-b*c))
    except EOFError:
        break

for i in range(len(x)):
    print("{:.3f} {:.3f}".format(x[i], y[i]))

Python: # coding: utf-8
# Your code here!
import numpy as np

while True:
    try:
        s=input().split()
        l=[int(s[0]),int(s[1]),int(s[3]),int(s[4])]
        lb=[int(s[2]),int(s[5])]
        l=np.dot(np.linalg.inv(np.array(l).reshape(2,2)),np.array(lb))
        print('%.3f %.3f' % (l[0],l[1]))
    except:
        break

Python: t = 0
while t == 0:	
	try:
		a,b,e,c,d,f = [int(i) for i in input().split()]
	except:
		break
	else:
		x = (d*e - b*f) / (a*d - b*c) + 0
		y = (a*f - c*e) / (a*d - b*c) + 0
		print("{0:.3f}".format(x) + "  " + "{0:.3f}".format(y))

Python: import sys

for line in sys.stdin:
    a, b, e, c, d, f = map(int, line.split())
    det = a * d - b * c
    a11 = d / det
    a12 = - b / det
    a21 = - c / det
    a22 = a / det
    print("%.3f %.3f" % (round(a11 * e + a12 * f, 3), round(a21 * e + a22 * f, 3)))

Python: # input
inputs = []
while True:
  try:
    inputs.append(list(map(float,input().split())))
  except EOFError:
    break

# calculation
for i in inputs:
  x=(i[2]*i[4]-i[1]*i[5])/(i[0]*i[4]-i[1]*i[3])
  y=(i[0]*i[5]-i[2]*i[3])/(i[0]*i[4]-i[1]*i[3])
  if x == -0.000:x=0
  if y == -0.000:y=0
  print("{0:.3f} {1:.3f}".format(x,y))

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

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)
print (ans1,ans2)

Python: import sys
import numpy as np

d = sys.stdin.readline()
while d:
    a,b,c,d,e,f = map(int,d.split())
    A = np.array([[a,b],[d,e]])
    B = np.array([c,f])
    x = np.linalg.inv(A).dot(B)
    print("%.3f %.3f"%(x[0],x[1]))

    d = sys.stdin.readline()

Python: try:
    s = []
    while True:
        l = list(map(float, input().split()))
        x = (l[2] * l[4] - l[5] * l[1]) / (l[0] * l[4] - l[3] * l[1])
        y = (l[2] - l[0] * x) / l[1]
        x_2 = "{0:.3f}".format(x)
        y_2 = "{0:.3f}".format(y)
        print(str(x_2) + " " + str(y_2))
except EOFError:
    pass

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

Python: import math
while True:
    try:
        list = [ float(x) for x in raw_input().split() ]
        x = (list[2]*list[4]-list[1]*list[5])/(list[0]*list[4]-list[1]*list[3])
        y = (list[0]*list[5]-list[2]*list[3])/(list[0]*list[4]-list[1]*list[3])
        
        print("%.3f %.3f" %(x, y))
        
    except EOFError:
        break

Python: def get_input():
    while True:
        try:
            yield ''.join(input())
        except EOFError:
            break

N = list(get_input())
for l in range(len(N)):
    a,b,c,d,e,f = [float(i) for i in N[l].split()]
    x = (c*e-f*b)/(a*e-b*d)
    y = (f*a-c*d)/(a*e-b*d)
    print(format(x+0.0,'.3f'), format(y+0.0,'.3f'))

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