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(int, input().split())
        x = (c*e - b*f)/(a*e - b*d)
        y = (a*f - c*d)/(a*e - b*d)
        print('{0:.3f}'.format(round(x)) +' {0:.3f}'.format(round(y)))
              
    except EOFError: break

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(f'{(c-b*y)/a:.3f} {y:.3f}')

Python: # coding=utf-8

while True:
    try:
        number_list = list(map(float, input().split()))
    except EOFError:
        break
    det = number_list[0]*number_list[4] - number_list[1]*number_list[3]
    inverse_list = [number_list[4] / det, -number_list[1] / det, -number_list[3] / det, number_list[0] / det]

    x = inverse_list[0]*number_list[2] + inverse_list[1]*number_list[5]
    y = inverse_list[2]*number_list[2] + inverse_list[3]*number_list[5]

    print('{0:.3f} {1:.3f}'.format(x, y))

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

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])
  print("{0:.3f} {1:.3f}".format(x,y))

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

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

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

Python: import math
import itertools

while 1:
    try:
        a, b, c, d, e, f = map(int, input().split())
        print('{0:.3f} {1:.3f}'.format((e*c-b*f)/(a*e-b*d)+0, (-d*c+a*f)/(a*e-b*d)+0))
    except:
        break

Python: import sys
from decimal import Decimal

def main():
    for input_line in sys.stdin:
        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: import numpy as np

while 1:
    try:
        a = list(map(float, input().split()))
        A = np.array([[a[0],a[1]],
                      [a[3],a[4]]])
        b = np.array([a[2],a[5]])
        x = np.linalg.solve(A, b)
        print(x)
    except EOFError:
        break

Python: x,y = [0]*2,[0]*2
for i in range(2):
    k = list(map(float,input().split()))
    n = k[0]*k[4] -k[1]*k[3]

    x[i],y[i] = (k[4]*k[2]-k[1]*k[5])/n,(-k[3]*k[2]+k[0]*k[5])/n    
    if x == 0:
        x = 0
    if y == 0:
        y = 0
for i in range(2):
    print("{0:0.3f} {1:0.3f}".format(x[i],y[i]))

Python: import sys
from math import fabs


if __name__ == '__main__':
    epsilon = 1e-8
    # ??????????????\?????¨???????????????
    for line in sys.stdin:
        a, b, e, c, d, f = [int(x) for x in line.strip().split(' ')]
        x = 1/(a*d-b*c) * (d*e - b*f)
        y = 1/(a*d-b*c) * (-c*e + a*f)
        # ?¨????????????¨?????? -0.0 ???????????´???????????¶?????? 0.0 ?????????
        #if fabs(x) < epsilon:
        #    x = 0.0
        #if fabs(y) < epsilon:
        #    y = 0.0
        print('{0:.3f}, {1:.3f}'.format(x+0.0, y+0.0))

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

Python: import sys

lines = []
for line in sys.stdin:
    num = line.split(" ")
    a, b, e, c, d, f = int(num[0]), int(num[1]), int(num[2]), int(num[3]), int(num[4]), int(num[5])
    x = (e*d-b*f)/(a*d-b*c)
    y = (a*f-e*c)/(a*d-b*c)
    if x == -0.0:
        x = 0.0
    if y == -0.0:
        y = 0.0
    print("{0:.3f} {1:.3f}".format(x,y))

Python: import numpy as np
while True:
    a,b,c,d,e,f = map(int, input().split())
    ls1 = [[a,b],[d,e]]
    ls2 = [c,f]
    x,y = np.linalg.solve(ls1,ls2)
    print("{0:.4f} {1:.4f}".format(x,y))

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

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

        y=float((c*d-f*a)/(b*d-e*a))
        x=float((c-b*y)/a)
        print("{0:.4f}".format(x)," ","{0:.4f}".format(y))
    except EOFError:
        break