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.Print(x)
		fmt.Println(".000")
		fmt.Print(y)
		fmt.Println(".000")
	}
}

Python: import sys
from decimal import Decimal

def main():
    for input_line in sys.stdin:
        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 = Decimal(y1 * multiplicand1)
    after_y2 = Decimal(y2 * multiplicand2)
    after_p = Decimal(p * multiplicand1)
    after_q = Decimal(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)
    y = round(y, 3)
    x = Decimal(p - y1 * y) / Decimal(x1)
    x = round(x, 3)
    print('%.3f %.3f' % (x, y))
    
if __name__ == '__main__':
    main()

Python: while 1:
    i = input().split()
    if i ==0:
        break
    else:
        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: for i in range(1,100000000):
    try:
        a,b,c,d,e,f=map(int,input().split())
        y=(a*f-d*c)/(e*a-b*d)
        x=(c-b*y)/a
        print(f'{x:.3f} {y:.3f}')
    except EOFError:
        break

Python: import sys
l=[[int(i) for i in l.split()] for l in sys.stdin]
for i in l:
    a,b,c,d,e,f=i
    x=round((c*e-b*f)/(a*e-b*d),3)
    y=round((c*d-a*f)/(b*d-a*e),3)
    if x==0:
        x=0
    if y==0:
        y=0
    print("{:.3f} {:.3f}".format(x,y))

Python: import sys

def mul4(v1, v2, v3, v4):
    return (v1 * v2) - (v3 * v4)

for i in sys.stdin:
    a, b, e, c, d, f = tuple(map(float, i.split()))
    det = mul4(a, d, c, b)
    print("{:.3f} {:.3f}".format(
        mul4(d, e, b, f) / det or 0.0,
        -mul4(c, e, a, f) / det or 0.0)
    )

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

if __name__ == "__main__":
    array = list(get_input())
    #print(array)
    for i in range(len(array)):
        a,b,c,d,e,f = array[i].split()
        
        if int(b)!=0:
            x = (int(b)*int(f) - int(c)*int(e))/(int(b)*int(d) - int(a)*int(e))
            y = -(int(a)/int(b))*x + int(c)/int(b)
        elif int(b)==0 and int(a)!=0:
            x = int(c)/int(a)
            y = -(int(d)/int(e))*x + int(f)
        
        print("{0} {1}".format(x,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 = (f*a - c*d)/(a*e - d*b)
        print( "{0:.3f} {1:.3f}".format(x,y))
    except:
        break

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

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

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

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

Python: a,b,c,d,e,f = [int(i) for i in input().split()]

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,c,d,e,f=list(map(int,line.split()))
    x=(c*e-b*f)/(a*e-b*d)
    y=(a*f-c*d)/(a*e-b*d)
    print("{0:.3f} {1:.3f}".format(x+0.0,y+0.0))

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

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

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

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

Python: while True:
    try:
        a,b,c,d,e,f=map(int,input().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))
    except:
        break

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)
                print("{:+.3f} {:+.3f}".format(x,y))
except:
        pass

Python: import sys
#import numpy as np
# AOJではnumpy使えません
#np.set_printoptions(formatter={'float': '{: 0.3f}'.format}) #桁を揃える

while True:
    line = sys.stdin.readline()
    if line is '':
        break
    #print(line)
    a = list(map(float, line.split(" ")))
    #print(a)
    tmp = a[0]
    for i in range(0, 3):
        a[i] = a[i] * a[3]
    for i in range(3, 6):
        a[i] = a[i] * tmp
    #print(a)
    y = (a[2] - a[5]) / (a[1] - a[4])
    x = (a[2] - a[1] * y) / a[0]
    print("{0:0.3f}".format(x), "{0:0.3f}".format(y))

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

Python: from sys import stdin
for line in stdin:
    a, b, c, d, e, f = map(float, line.split())
    anss = ['%.3f' % ((c * e - f * b) / (a * e - b * d)), '%.3f' % ((c * d - a * f) / (b * d - a * e))]
    for index, ans in enumerate(anss):
        if ans == '-0.000':
            anss[index] = '0.000'
    print(' '.join(anss))

Python: while True:
	try:
		a,b,c,d,e,f = map(float,raw_input().split(' '))
		print (c*e-b*f)/(a*e-b*d),(a*f-c*d)/(a*e-b*d)
	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))