Go: package main

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

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]
		var mulA, mulD int
		if a < 0 {
			mulA = a * -1
		} else {
			mulA = a
		}
		if d < 0 {
			mulD = d * -1
		} else {
			mulD = d
		}
		a *= mulD
		b *= mulD
		c *= mulD
		d *= mulA
		e *= mulA
		f *= mulA

		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: import sys
for line in sys.stdin.readlines():
#for line in data.split('\n'):
	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)
	if round(x,3) == 0.0:
		x = 0.0
	if round(y,3) == 0.0:
		y = 0.0
	print('{0:.3f} {1:.3f}'.format(x,y))

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

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

Python: x = float(0.000)
y = float(0.000)

while 1:
	try:
		data = raw_input().split()

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

		# a*x + b*y = c
		# d*x + e*y = f

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

		print(float(format(x, '.3f')))
		print(float(format(y, '.3f')))

	except:
		break

Python: def main():
    def get_inputs():
        li = []
        try:
            while True:
                li.append(input())
        except EOFError:
            return li

    li = get_inputs()
    for str_num in li:
        tmp = str_num.split(" ")
        for i in range(len(tmp)):
            tmp[i] = int(tmp[i])
        a,b,c,d,e,f = tmp[0],tmp[1],tmp[2],tmp[3],tmp[4],tmp[5]
        x = (c*e - b*f) / (a*e - b*d)
        x = round(x, 3)
        y = (c*d - a*f) / (b*d - a*e)
        y = round(y, 3)
        print("{} {}".format(x,y))
    return None


if __name__ == '__main__':
    main()

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 ("%f %f" % (x, y))
    except:
        break

Python: from decimal import Decimal

def main():
    input_line = raw_input()
    x1 = int(input_line.split(' ')[0])
    y1 = int(input_line.split(' ')[1])
    p = int(input_line.split(' ')[2])
    x2 = int(input_line.split(' ')[3])
    y2 = int(input_line.split(' ')[4])
    q = int(input_line.split(' ')[5])
    multiplicand1, multiplicand2 = calculate1(x1, x2)
    after_y1, after_y2, after_p, after_q = calculate2(y1, y2, p, q, multiplicand1, multiplicand2)
    calculate3(after_y1, after_y2, after_p, after_q, x1, y1, p)
    
def calculate1(x1, x2):
    if (x1 >= 0 and x2 >= 0) or (x1 < 0 and x2 < 0):
        multiplicand1 = -x2
        multiplicand2 = x1
        return multiplicand1, multiplicand2
    else:
        multiplicand1 = abs(x2)
        multiplicand2 = abs(x1)
        return multiplicand1, multiplicand2
    
def calculate2(y1, y2, p, q, multiplicand1, multiplicand2):
    after_y1 = y1 * multiplicand1
    after_y2 = y2 * multiplicand2
    after_p = p * multiplicand1
    after_q = q * multiplicand2
    return after_y1, after_y2, after_p, after_q

def calculate3(after_y1, after_y2, after_p, after_q, x1, y1, p):
    y = Decimal(after_p + after_q) / Decimal(after_y1 + after_y2)
    x = Decimal(p - y1 * y) / Decimal(x1)
    print('%.4f %.4f' % (x, y))
    
if __name__ == '__main__':
    main()

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:
    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: #連立方程式 標準機能のみで
import numpy as np

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 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:
    y = (l[2]*l[3]-l[0]*l[5])/(l[1]*l[3]-l[0]*l[4])
    
    x = (l[2]-l[1]*y)/l[0]
    
    print("{:.3f} {:.3f} ".format(x,y))

Python: while True:
    try:
        a,b,c,d,e,f=map(int,input().split())
        x=(c*e-b*f)/(a*e-b*d)
        y=(c-a*x)/b
        if x==-0:
            x=0
        if y==-0:
            y=0
        print(f'{x:.3f} {y:.3f}')
    except EOFError:
        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:
    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: # coding: utf-8
# Your code here!
import numpy as np
while True:
    try:
        a,b,c,d,e,f = map(int, input().split())
        x,y=map(float,np.dot(np.linalg.inv(np.array([a,b,d,e]).reshape(2,2)),np.array([c,f])))
        print('%.3f %.3f' % (x,y))
    except:
        break

Python: import sys

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

Python: from decimal import Decimal, ROUND_HALF_UP, ROUND_HALF_EVEN
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:
         x=int(x)
      if y==-0:
         y=int(y)
      X = Decimal(x).quantize(Decimal('0.001'), rounding=ROUND_HALF_UP)
      Y = Decimal(y).quantize(Decimal('0.001'), rounding=ROUND_HALF_UP)
      print(f'{X:.3f} {Y:.3f}')
   except EOFError:
      break

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

Python: x = int(0)
y = int(0)

while 1:
	try:
		data = raw_input().split()

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

		# a*x + b*y = c
		# d*x + e*y = f

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

		print(float(format(x, '.3f')))
		print(float(format(y, '.3f')))

	except:
		break

Python: print('hello')

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

Python: # -*- coding: utf-8 -*-

import sys
import os


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

    delta = a * e - b * d
    if delta == 0:
        break
    else:
        x = 1 / delta * (e * c - b * f)
        y = 1 / delta * (-d * c + a * f)
        print('{:.3f} {:.3f}'.format(x + 0, y + 0))