s_id stringlengths 10 10 | p_id stringlengths 6 6 | u_id stringlengths 10 10 | date stringlengths 10 10 | language stringclasses 1 value | original_language stringclasses 11 values | filename_ext stringclasses 1 value | status stringclasses 1 value | cpu_time stringlengths 1 5 | memory stringlengths 1 7 | code_size stringlengths 1 6 | code stringlengths 1 539k |
|---|---|---|---|---|---|---|---|---|---|---|---|
s512628616 | p00004 | u982618289 | 1455121554 | Python | Python3 | py | Runtime Error | 0 | 0 | 265 | while True:
try:
a, b, c, d, e, f = map(float, input().split())
det = e*a - b*d
if det !=0:
x = (e*c - b*f)/det
y = (f*a - c*d)/det
print("{:.3f} {:.3f)".format(x+0,y+0))
except EOFError:
break |
s242601939 | p00004 | u982618289 | 1455122919 | Python | Python3 | py | Runtime Error | 0 | 0 | 191 | 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)) |
s880992382 | p00004 | u982618289 | 1455123021 | Python | Python3 | py | Runtime Error | 0 | 0 | 190 | 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)) |
s521275428 | p00004 | u982618289 | 1455123030 | Python | Python3 | py | Runtime Error | 0 | 0 | 193 | 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)) |
s084241538 | p00004 | u982618289 | 1455123086 | Python | Python3 | py | Runtime Error | 0 | 0 | 191 | 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)) |
s694455848 | p00004 | u982618289 | 1455123110 | Python | Python3 | py | Runtime Error | 0 | 0 | 191 | 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)) |
s270111010 | p00004 | u982618289 | 1455123496 | Python | Python3 | py | Runtime Error | 0 | 0 | 196 | import sys
for line sys.stdin:
a,b,c,d,e,f = map(int, line.split())
z = a * e - b * c
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) |
s707244346 | p00004 | u982618289 | 1456645105 | Python | Python3 | py | Runtime Error | 0 | 0 | 199 | import sys
for line in sys.stdin:
a,b,c,d,e,f= map(int,line.split())
det=a*e-b*d
if(det!=0):
x=(c*e-b*f)/det
y=(a*f-c*d)/det
print("{0:.3f} {1:.3f)".format(x+0, y+0)) |
s312025243 | p00004 | u982618289 | 1456645323 | Python | Python3 | py | Runtime Error | 0 | 0 | 199 | import sys
for line in sys.stdin:
a,b,c,d,e,f= map(int,line.split())
det=a*e-b*d
if(det!=0):
x=(c*e-b*f)/det
y=(a*f-c*d)/det
print("{0:.3f} {1:.3f)".format(x+0, y+0)) |
s573199476 | p00004 | u075836834 | 1457978985 | Python | Python3 | py | Runtime Error | 0 | 0 | 218 | while True:
try:
A=[int(j) for j in input().split()]
a=A[3]/A[0]
for i in range(3):
A[i]*=a
for i in range(3):
A[i]=A[i]-A[i+3]
y=A[2]/A[1]
x=(A[5]-A[4]*y)/A[3]
print(x,y)
except EOFError:
break |
s175581795 | p00004 | u075836834 | 1457979092 | Python | Python3 | py | Runtime Error | 0 | 0 | 232 | while True:
try:
A=[int(j) for j in input().split()]
a=A[3]/A[0]
for i in range(3):
A[i]*=a
for i in range(3):
A[i]=A[i]-A[i+3]
y=A[2]/A[1]
x=(A[5]-A[4]*y)/A[3]
print("%f %f"%(x+0,y+0))
except EOFError:
break |
s613944684 | p00004 | u148101999 | 1458210437 | Python | Python | py | Runtime Error | 0 | 0 | 244 | import numpy as np
import sys
for i in sys.stdin:
a,b,c,d,e,f = map(float, i.split())
A = np.array([[ a, b],
[ d, e]])
B = np.array([c,f])
X = np.linalg.solve(A,B)
print "{0:.3f}".format(X[0]),"{0:.3f}".format(X[1]) |
s279130476 | p00004 | u148101999 | 1458265770 | Python | Python | py | Runtime Error | 0 | 0 | 245 |
import numpy as np
import sys
for i in sys.stdin:
a,b,c,d,e,f = map(float, i.split())
A = np.array([[ a, b],
[ d, e]])
B = np.array([c,f])
X = np.linalg.solve(A,B)
print "{0:.3f}".format(X[0]),"{0:.3f}".format(X[1]) |
s347371906 | p00004 | u148101999 | 1458266133 | Python | Python | py | Runtime Error | 0 | 0 | 330 |
import numpy as np
import sys
printf = sys.stdout.write
for i in sys.stdin:
try:
a,b,c,d,e,f = map(float, i.split())
except:
printf(i)
break
A = np.array([[ a, b],
[ d, e]])
B = np.array([c,f])
X = np.linalg.solve(A,B)
print "{0:.3f}".format(X[0]),"{0:.3f}".format(X[1]) |
s023610268 | p00004 | u130979865 | 1459853852 | Python | Python | py | Runtime Error | 0 | 0 | 164 | # -*- coding: utf-8 -*-
import sys
for i in sys.stdin:
a, b, c, d, e, f = map(int, line.split())
print "%f %f" %((d*c-a*f)/(b*d-a*e), (b*f-c*e)/(b*d-a*e)) |
s355902051 | p00004 | u957021485 | 1465557759 | Python | Python3 | py | Runtime Error | 0 | 0 | 333 | import itertools
import operator
dataset = []
while True:
try:
dataset.append(input())
except EOFError:
break
for item in dataset:
a, b, c, d, e, f = [int(i) for i in item.split()]
e = e * (a/d)
f = f * (a/d)
y = (c - f)/(b-e)
x = (c - b*y) / a
print("{:.3f} {:.3f}".format(x, y)) |
s836382797 | p00004 | u957021485 | 1465557809 | Python | Python3 | py | Runtime Error | 0 | 0 | 333 | import itertools
import operator
dataset = []
while True:
try:
dataset.append(input())
except EOFError:
break
for item in dataset:
a, b, c, d, e, f = [int(i) for i in item.split()]
e = e * (a/d)
f = f * (a/d)
y = (c - f)/(b-e)
x = (c - b*y) / a
print("{:.3f} {:.3f}".format(x, y)) |
s001505363 | p00004 | u957021485 | 1465557989 | Python | Python3 | py | Runtime Error | 0 | 0 | 299 | dataset = []
while True:
try:
dataset.append(input())
except EOFError:
break
for item in dataset:
a, b, c, d, e, f = [int(i) for i in item.split()]
e = e * (a/d)
f = f * (a/d)
y = (c - f)/(b-e)
x = (c - b*y) / a
print("{:.3f} {:.3f}".format(x, y)) |
s699457331 | p00004 | u957021485 | 1465558614 | Python | Python3 | py | Runtime Error | 0 | 0 | 421 | import itertools
import operator
dataset = []
while True:
try:
dataset.append(input())
except EOFError:
break
for item in dataset:
try:
a, b, c, d, e, f = [int(i) for i in item.split()]
except:
print("dataset cannot to be converted")
break
e = e * (a/d)
f = f * (a/d)
y = (c - f)/(b-e)
x = (c - b*y) / a
print("{:.3f} {:.3f}".format(x, y)) |
s172502710 | p00004 | u957021485 | 1465561746 | Python | Python3 | py | Runtime Error | 0 | 0 | 306 | import sys
dataset = sys.stdin.readlines()
for item in dataset:
a, b, c, d, e, f = list(map(int, item.split()))
k1 = e * (a/d)
k2 = f * (a/d)
y = (c * d - f * a)/(b * d - e * a)
x = (c * e - b * f) / (a * e - b * d)
if x == 0:
x = 0
print("{:.3f} {:.3f}".format(x, y)) |
s730392876 | p00004 | u765849500 | 1466178575 | Python | Python | py | Runtime Error | 0 | 0 | 165 | while 1:
a,b,c,d,e,f = map(int,raw_input().split())
i = d/a
j = i*b-e
k = i*c-f
y = float(k/j)
x = float(c-b*y)/a
print "%.3f %.3f"%(x,y) |
s300768844 | p00004 | u765849500 | 1466178664 | Python | Python | py | Runtime Error | 0 | 0 | 167 | while 1:
a,b,c,d,e,f = map(float,raw_input().split())
i = d/a
j = i*b-e
k = i*c-f
y = float(k/j)
x = float(c-b*y)/a
print "%.3f %.3f"%(x,y) |
s448693302 | p00004 | u589886885 | 1471935183 | Python | Python3 | py | Runtime Error | 0 | 0 | 201 | mport sys
for i in sys.stdin.readlines():
a, b, c, d, e, f = [int(x) for x in i.split()]
y = (c * d - a * f) / (b * d - a * e)
x = (c - b * y) / a
print('{0:.3f} {1:.3f}'.format(x, y)) |
s811842269 | p00004 | u393305246 | 1474110509 | Python | Python | py | Runtime Error | 0 | 0 | 206 | for i in range(2):
inl=map(int, raw_input().split())
x=(int[2]*int[4]-int[5]*int[1])/(int[0]*int[4]-int[3]*int[1])+0.000
y=(int[2]*int[3]-int[5]*int[0])/(int[1]*int[3]-int[4]*int[0])+0.000
print x,y |
s981944592 | p00004 | u505912349 | 1475844908 | Python | Python3 | py | Runtime Error | 0 | 0 | 332 | for line in sys.stdin:
array = [float(x) for x in line.split()]
ar1 = array[0:3]
ar2 = array[3:]
i = ar1[0]
ar1 = [x*ar2[0] for x in ar1]
ar2 = [x*i for x in ar2]
y = (ar1[2] - ar2[2])/(ar1[1]-ar2[1])
ar1 = array[0:3]
x = (ar1[2]-ar1[1]*y)/ar1[0]
print('%.3f %.3f' % (round(x,3), round(y,3))) |
s741235159 | p00004 | u813534019 | 1477068170 | Python | Python | py | Runtime Error | 0 | 0 | 175 | import sys
for l in sys.stdin:
a,b,c,d,e,f = map(float, l.split())
x = (c*e -f*b) / (a*e - d*b)
y = (f - d*x) / e
print "%0.3f %0.3f" %(round(x,3), round(y,3)) |
s863944979 | p00004 | u813534019 | 1477068257 | Python | Python | py | Runtime Error | 0 | 0 | 169 | import sys
for l in sys.stdin:
a,b,c,d,e,f = map(float, l.split())
x = (c*e -f*b) / (a*e - d*b)
y = (f - d*x) / e
print "%f %f" %(round(x,3), round(y,3)) |
s358501629 | p00004 | u813534019 | 1477068328 | Python | Python | py | Runtime Error | 0 | 0 | 169 | import sys
for l in sys.stdin:
a,b,c,d,e,f = map(int, l.split())
x = (c*e -f*b) / (a*e - d*b)
y = (f - d*x) / e
print "%f %f" %(round(x,3), round(y,3))
|
s019391497 | p00004 | u813534019 | 1477069032 | Python | Python | py | Runtime Error | 0 | 0 | 155 | import sys
for l in sys.stdin:
a,b,c,d,e,f = map(float, l.split())
x = (c*e -f*b) / (a*e - d*b)
y = (f - d*x) / e
print "%.3f %.3f" %(x, y) |
s048604133 | p00004 | u776559258 | 1477534910 | Python | Python3 | py | Runtime Error | 0 | 0 | 172 | def gcd(a,b):
if b==0:
return a
return gcd(b,a%b)
while True:
try:
a,b=[int(i) for i in input().split()]
print(gcd(a,b),a*b/gcd(a,b))
except EOFError:
break
|
s228862692 | p00004 | u766597310 | 1477669589 | Python | Python3 | py | Runtime Error | 0 | 0 | 476 | from sys import stdin
def deal(x):
if abs(x) < 1e-6: return 0
else: return x
def solve(a, b, c, d, e, f):
x = 0
y = 0
if b == 0:
x = c / a
y = (f - d * x) / e
else:
x = (b * f - e * c) / (b * d - e * a)
y = (c - a * x) / b
p = [deal(x), deal(y)]
return p
for s in stdin:
s = s[:-1]
s = map(float, s.split())
p = solve(s[0], s[1], s[2], s[3], s[4], s[5])
print ("%.3f "%p[0] + "%.3f"%p[1]) |
s971826416 | p00004 | u114472050 | 1477669760 | Python | Python3 | py | Runtime Error | 0 | 0 | 166 | import sys
for line in sys.stdin:
a,b,c,d,e,f = [float(w) for w in line.split()]
print("{:.3f} {:.3f}".format((e*c-b*f)/(a*e-a*b), (d*c-a*f)/(b*d-a*e))) |
s372817788 | p00004 | u545973195 | 1477710389 | Python | Python3 | py | Runtime Error | 0 | 0 | 205 | 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) |
s502620357 | p00004 | u542645301 | 1479478187 | Python | Python3 | py | Runtime Error | 0 | 0 | 236 | [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 sys.stdin for k in [[int(j) for j in i.split()]]] |
s617327860 | p00004 | u542645301 | 1479478266 | Python | Python3 | py | Runtime Error | 0 | 0 | 238 | [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 sys.stdin for k in [int(j) for j in i.split()]] |
s423778741 | p00004 | u542645301 | 1479478517 | Python | Python3 | py | Runtime Error | 0 | 0 | 243 | [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 sys.stdin for k in [[int(float(j)) for j in i.split()]]] |
s692098736 | p00004 | u292012552 | 1479792208 | Python | Python3 | py | Runtime Error | 0 | 0 | 272 | import sys
for line in sys.stdin:
a, b, c, d, e, f = map(int, input().split())
if b == 0:
x = c / a
y = (f - d * x) / e
elif e == 0:
x = f / d
y = (c - a * x) / b
else:
x = (c * e - f * b) / (a * e - d * b)
y = (f - d * x) / e
print(x, end=" ")
print(y) |
s842474159 | p00004 | u546285759 | 1480327305 | Python | Python3 | py | Runtime Error | 0 | 0 | 251 | while True:
try:
a, b, c, d, e, f = map(int, input().split())
tb, tc = d*b, d*c
te, tf = a*e, a*f
y = (tc-tf)//(tb-te)
x = (c-(y*b))//a
print("{:.3f} {:.3f}".format(x, y))
except:
return |
s151585650 | p00004 | u086566114 | 1480511141 | Python | Python | py | Runtime Error | 0 | 0 | 176 | import sys
for line in sys.stdin():
[a,b,e,c,d,f] = [int(x) for x in line.split()]
delta = a*d-b*c
x = (d*e-b*f)/delta
y = (-e*c+a*f)/delta
print x,y
|
s232393351 | p00004 | u166860661 | 1480771646 | Python | Python | py | Runtime Error | 0 | 0 | 233 | #coding: utf-8
import sys
for line in sys.stdin:
l = (map(int,line.split()))
a, b, c, d, e, f = l
x = float(c*e - b*f) / float(a*e - b*d)
y = float(c*d - a*f) / float(b*d - a*e)
print print "%.3f" %x , "%.3f" %y |
s654216496 | p00004 | u166860661 | 1480772435 | Python | Python | py | Runtime Error | 0 | 0 | 254 | for line in sys.stdin:
l = (map(float,line.split()))
a = l[0]
b = 1[1]
c = l[2]
d = 1[3]
e = l[4]
f = 1[5]
x = float(c*e - b*f) / float(a*e - b*d)
y = float(c*d - a*f) / float(b*d - a*e)
print "%.3f" %x , "%.3f" %y |
s900227491 | p00004 | u166860661 | 1480772458 | Python | Python | py | Runtime Error | 0 | 0 | 282 | #coding: utf-8
import sys
for line in sys.stdin:
l = (map(float,line.split()))
a = l[0]
b = 1[1]
c = l[2]
d = 1[3]
e = l[4]
f = 1[5]
x = float(c*e - b*f) / float(a*e - b*d)
y = float(c*d - a*f) / float(b*d - a*e)
print "%.3f" %x , "%.3f" %y |
s257261214 | p00004 | u745277023 | 1483693988 | Python | Python3 | py | Runtime Error | 0 | 0 | 423 | 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) |
s271040468 | p00004 | u393305246 | 1488292987 | Python | Python | py | Runtime Error | 0 | 0 | 248 | ini=map(int, raw_input()split())
x=(ini[2]*ini[4]-ini[1]*ini[5])/(ini[0]*ini[4]-ini[1]*ini[3])*1.0
y=(ini[2]*ini[3]-ini[0]*ini[5])/(ini[1]*ini[3]-ini[0]*ini[4])*1.0
xx=round(x,3)
yy=round(y,3)
xxx=('%4.3f' % xx)
yyy=('%4.3f' % yy)
print xxx,yyy |
s825670145 | p00004 | u421925564 | 1489126007 | Python | Python3 | py | Runtime Error | 0 | 0 | 402 | #_*_ coding:utf-8 _*_
2 import sys
3
4
5 while True:
6 vals = sys.stdin.readline()
7 if(vals is None or vals.strip() == '' ):
8 break
9 a,b,c,d,e,f=list( map(float,vals.strip().split()))
10 temp = a * e - d * b
11 print(temp)
12 x = (c * e - b * f) / temp + 0.0
13 y = (c * d - a * f) / -temp + 0.0
14 print('%.3f %.3f' % (x,y))
15 |
s113624838 | p00004 | u421925564 | 1489126150 | Python | Python3 | py | Runtime Error | 0 | 0 | 376 | #_*_ coding:utf-8 _*_
import sys
while True:
vals = sys.stdin.readline()
if(vals is None or vals.strip() == '' ):
break
a,b,c,d,e,f=list( map(float,vals.strip().split()))
temp = a * e - d * b
print(temp)
x = (c * e - b * f) / temp + 0.0
y = (c * d - a * f) / -temp + 0.0
print('%.3f %.3f' % (x,y))
|
s841115116 | p00004 | u921541953 | 1489919178 | Python | Python3 | py | Runtime Error | 0 | 0 | 178 | import sys
from sympy import *
for s in sys.stdin:
a,b,c,d,e,f = map(int, s.split())
x, y = symbols('x y')
init_printing()
solve([a*x + b*y - c],[d*x + e*y - f]) |
s132301768 | p00004 | u011621222 | 1490071843 | Python | Python | py | Runtime Error | 0 | 0 | 141 | while 1:
try:
a,b,c,d,e,f=map(int,raw_input().split())
print"%.3f %.3f"%(float(c*e-b*f)/(a*e-b*d),float(a*f-c*d)/(a*e-b*d)
except:break |
s115992474 | p00004 | u509278866 | 1491803008 | Python | Python3 | py | Runtime Error | 0 | 0 | 822 | import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time
import numpy as np
sys.setrecursionlimit(10**7)
inf = 10**20
mod = 10**9 + 7
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
def main():
sa = [s for s in sys.stdin.read().split('\n') if s]
r = []
for s in sa:
a,b,c,d,e,f = [int(x) for x in s.split()]
A = np.matrix([[a,b],[d,e]])
B = np.array([c,f])
AT = np.linalg.inv(A)
x = np.dot(AT, B)
r.append('{:01.3f} {:01.3f}'.format(x[0,0], x[0,1]))
return '\n'.join(r)
print(main()) |
s111549965 | p00004 | u319774425 | 1494320254 | Python | Python | py | Runtime Error | 0 | 0 | 355 | import math
l = map(float, raw_input().split())
# adjusting d to a
a = l[0]/l[3]
l[3] = a * l[3]
l[4] = a * l[4]
l[5] = a * l[5]
# calculating y
y_1 = l[1] - l[4]
y_2 = l[2] - l[5]
y_answer = y_2/y_1
# calculatiing x
x_answer = (l[2] - l[1] * y_answer)/l[0]
x_answer = round(x_answer)
y_answer = round(y_answer)
print "%f %f" % (x_answer, y_answer) |
s256843021 | p00004 | u319774425 | 1494320324 | Python | Python | py | Runtime Error | 0 | 0 | 355 | import math
l = map(float, raw_input().split())
# adjusting d to a
a = l[0]/l[3]
l[3] = a * l[3]
l[4] = a * l[4]
l[5] = a * l[5]
# calculating y
y_1 = l[1] - l[4]
y_2 = l[2] - l[5]
y_answer = y_2/y_1
# calculatiing x
x_answer = (l[2] - l[1] * y_answer)/l[0]
x_answer = round(x_answer)
y_answer = round(y_answer)
print "%f %f" % (x_answer, y_answer) |
s455949395 | p00004 | u319774425 | 1494321397 | Python | Python | py | Runtime Error | 0 | 0 | 506 | import sys
a = []
for line in sys.stdin:
a.append(map(float, raw_input().strip()))
for i in range(a):
# adjusting d to a
a = l[i][0]/l[i][3]
l[i][3] = a * l[3]
l[i][4] = a * l[4]
l[5] = a * l[5]
# calculating y
y_1 = l[i][1] - l[i][4]
y_2 = l[i][2] - l[i][5]
y_answer = y_2/y_1
# calculatiing x
x_answer = (l[i][2] - l[i][1] * y_answer)/l[i][0]
x_answer = round(x_answer)
y_answer = round(y_answer)
print "%3f %3f" % (x_answer, y_answer) |
s547073789 | p00004 | u123596571 | 1494651768 | Python | Python3 | py | Runtime Error | 0 | 0 | 177 | 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)
print("{0:.3f} {0:.3f}".format(x,y)
except:
exit() |
s452148559 | p00004 | u123596571 | 1494651797 | Python | Python3 | py | Runtime Error | 0 | 0 | 176 | 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)
print("{0:.3f} {0:.3f}".format(x,y)
except:
break |
s800433401 | p00004 | u340500592 | 1499405630 | Python | Python3 | py | Runtime Error | 0 | 0 | 187 | for line in sys.stdin:
a, b, c, d, e, f = map(float, input().split())
x = (c * e - f * b) / (a * e - d * b)
y = (c * d - f * a) / (b * d - e * a)
print('{0:.3f} {1:.3f}'.format(x, y)) |
s701671863 | p00004 | u340500592 | 1499405705 | Python | Python3 | py | Runtime Error | 0 | 0 | 199 | import sys
for line in sys.stdin:
a, b, c, d, e, f = map(float, input().split())
x = (c * e - f * b) / (a * e - d * b)
y = (c * d - f * a) / (b * d - e * a)
print('{0:.3f} {1:.3f}'.format(x, y)) |
s735252607 | p00004 | u914146430 | 1500346017 | Python | Python3 | py | Runtime Error | 0 | 0 | 249 | import sys
import numpy as np
for line in sys.stdin:
a11,a12,b1,a21,a22,b2 = list(map(int, line.split()))
A=np.array([[a11,a12],[a21,a22]])
B=np.array([b1,b2])
x,y=np.linalg.solve(A,B)
print("{0:.3f} {1:.3f}".format(x,y)) |
s428017037 | p00004 | u914146430 | 1500346103 | Python | Python3 | py | Runtime Error | 0 | 0 | 249 | import sys
import numpy as np
for line in sys.stdin:
a11,a12,b1,a21,a22,b2 = list(map(int, line.split()))
A=np.array([[a11,a12],[a21,a22]])
B=np.array([b1,b2])
x,y=np.linalg.solve(A,B)
print("{0:.3f} {1:.3f}".format(x,y)) |
s010576554 | p00004 | u914146430 | 1500347491 | Python | Python3 | py | Runtime Error | 0 | 0 | 174 | import sys
for line in sys.stdin:
a,b,c,d,e,f=list(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} {1:.3f}".format(x,y)) |
s184575022 | p00004 | u914146430 | 1500347517 | Python | Python3 | py | Runtime Error | 0 | 0 | 174 | import sys
for line in sys.stdin:
a,b,c,d,e,f=list(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} {1:.3f}".format(x,y)) |
s484802846 | p00004 | u498511622 | 1501252741 | Python | Python3 | py | Runtime Error | 0 | 0 | 118 | from numpy.linalg import solve
a,b,c,d,e,f=map(int,input(),split())
A=[[1.,2],[4,5]]
B=[3,6]
xy=solve(A,B)
print(xy) |
s765549365 | p00004 | u350064373 | 1501252896 | Python | Python3 | py | Runtime Error | 0 | 0 | 190 | 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)) |
s440844390 | p00004 | u350064373 | 1501253051 | Python | Python3 | py | Runtime Error | 0 | 0 | 245 | import numpy as np
while True:
try:
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))
except:
break |
s545928261 | p00004 | u264972437 | 1503045323 | Python | Python3 | py | Runtime Error | 0 | 0 | 189 | 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)) |
s262897814 | p00004 | u264972437 | 1503045410 | Python | Python3 | py | Runtime Error | 0 | 0 | 189 | 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)) |
s227948005 | p00004 | u264972437 | 1503045592 | Python | Python3 | py | Runtime Error | 0 | 0 | 182 | import sys
for line in sys.stdin.readlines()
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)) |
s375524241 | p00004 | u733159526 | 1503268166 | Python | Python3 | py | Runtime Error | 0 | 0 | 301 | '''
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) |
s155308183 | p00004 | u733159526 | 1503268213 | Python | Python3 | py | Runtime Error | 0 | 0 | 305 | '''
'''
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) |
s675863853 | p00004 | u733159526 | 1503268244 | Python | Python3 | py | Runtime Error | 0 | 0 | 224 | 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) |
s289327540 | p00004 | u733159526 | 1503268646 | Python | Python3 | py | Runtime Error | 0 | 0 | 169 | 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)) |
s503017834 | p00004 | u733159526 | 1503268686 | Python | Python3 | py | Runtime Error | 0 | 0 | 169 | 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)) |
s058313536 | p00004 | u733159526 | 1503273057 | Python | Python3 | py | Runtime Error | 0 | 0 | 169 | 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)) |
s910239983 | p00004 | u733159526 | 1503273083 | Python | Python3 | py | Runtime Error | 0 | 0 | 169 | 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)) |
s267085627 | p00004 | u105694406 | 1504164301 | Python | Python3 | py | Runtime Error | 0 | 0 | 198 | while True:
a, b, c, d, e, f = map(int, input().split())
x = (f*b - e*c)/(d*b - e*a)
y = (c + f - x*(a+d))/(b+e)
print(round(x,3))
print('{:.3f} {:.3f}'.format(round(x,3)+0.0,round(y,3)+0.0)) |
s983403549 | p00004 | u105694406 | 1504164461 | Python | Python3 | py | Runtime Error | 0 | 0 | 206 | import sys
a = []
for line in sys.stdin:
a, b, c, d, e, f = map(int, line.split())
x = (f*b - e*c)/(d*b - e*a)
y = (c + f - x*(a+d))/(b+e)
print('{:.3f} {:.3f}'.format(round(x,3)+0.0,round(y,3)+0.0)) |
s976320251 | p00004 | u105694406 | 1504164642 | Python | Python3 | py | Runtime Error | 0 | 0 | 236 | import sys
a = []
for line in sys.stdin:
a.append(line)
for s in a:
a, b, c, d, e, f = map(int, a.split())
x = (f*b - e*c)/(d*b - e*a)
y = (c + f - x*(a+d))/(b+e)
print('{:.3f} {:.3f}'.format(round(x,3)+0.0,round(y,3)+0.0)) |
s822707300 | p00004 | u105694406 | 1504164706 | Python | Python3 | py | Runtime Error | 0 | 0 | 245 | import sys
strs = []
for line in sys.stdin:
strs.append(line)
for s in strs:
a, b, c, d, e, f = map(int, s.split())
x = (f*b - e*c)/(d*b - e*a)
y = (c + f - x*(a+d))/(b+e)
print('{:.3f} {:.3f}'.format(round(x,3)+0.0,round(y,3)+0.0)) |
s536628092 | p00004 | u105694406 | 1504164961 | Python | Python3 | py | Runtime Error | 0 | 0 | 245 | import sys
strs = []
for line in sys.stdin:
strs.append(line)
for s in strs:
a, b, c, d, e, f = map(int, s.split())
x = (f*b - e*c)/(d*b - e*a)
y = (c + f - x*(a+d))/(b+e)
print('{:.3f} {:.3f}'.format(round(x,3)+0.0,round(y,3)+0.0)) |
s693020112 | p00004 | u184989919 | 1505656310 | Python | Python3 | py | Runtime Error | 0 | 0 | 232 |
def SimultaneousEquation():
for line in sys.stdin:
a,b,c,d,e,f=map(float,line.split())
y=(c*d-f*a)/(b*d-e*a)
x=(c-b*y)/a
print("{0:.3f} {1:.3f}".format(x,y))
SimultaneousEquation() |
s994109775 | p00004 | u933096856 | 1505794446 | Python | Python3 | py | Runtime Error | 0 | 0 | 149 | try:
while True:
a,b,c,d,e,f=map(int, input().split())
print( (c*e-b*f)/)a*e-b*d), (a*f-c*d)/(a*e-b*d))
except EOFError:
pass |
s966187469 | p00004 | u506705885 | 1506435443 | Python | Python3 | py | Runtime Error | 0 | 0 | 530 | answers=[]
while True:
try:
numbers=input().split()
for i in range(6):
numbers[i]=float(numbers[i])
times=numbers[0]/numbers[3]
numbers[3]=numbers[3]*times
numbers[4]=numbers[4]*times
numbers[5]=numbers[5]*times
y=(numbers[2]-numbers[5])/(numbers[1]-numbers[4])
x=(numbers[2]-numbers[1]*y)/numbers[0]
answers.append(x)
answers.append(y)
except:
break
for i in range(len(answers)/2):
print(answers[i*2],answers[i*2+1]) |
s788404843 | p00004 | u506705885 | 1506435871 | Python | Python3 | py | Runtime Error | 0 | 0 | 234 | 1
2
3
4
5
6
7
import sys
??
for i in sys.stdin.readlines():
????????a, b, c, d, e, f = [int(x) for x in i.split()]
????????y = (c * d - a * f) / (b * d - a * e)
????????x = (c - b * y) / a
????????print('{0:.3f} {1:.3f}'.format(x, y)) |
s877244708 | p00004 | u506705885 | 1506435877 | Python | Python3 | py | Runtime Error | 0 | 0 | 221 |
import sys
??
for i in sys.stdin.readlines():
????????a, b, c, d, e, f = [int(x) for x in i.split()]
????????y = (c * d - a * f) / (b * d - a * e)
????????x = (c - b * y) / a
????????print('{0:.3f} {1:.3f}'.format(x, y)) |
s103330469 | p00004 | u506705885 | 1506435895 | Python | Python3 | py | Runtime Error | 0 | 0 | 219 | import sys??
for i in sys.stdin.readlines():
????????a, b, c, d, e, f = [int(x) for x in i.split()]
????????y = (c * d - a * f) / (b * d - a * e)
????????x = (c - b * y) / a
????????print('{0:.3f} {1:.3f}'.format(x, y)) |
s137082828 | p00004 | u343251190 | 1507221551 | Python | Python3 | py | Runtime Error | 0 | 0 | 173 | import sys
for line in sys.stdin:
a,b,c,d,e,f = map(int, line.split())
y = (c/a - f/d)/(b/a - e/d)
x = -(e/d) * y + (f/d)
print("{:.3f} {:.3f}".format(x, y)) |
s644074656 | p00004 | u343251190 | 1507221643 | Python | Python3 | py | Runtime Error | 0 | 0 | 165 | import sys
for line in sys.stdin:
a,b,c,d,e,f = map(int, line.split())
y = (c/a - f/d)/(b/a - e/d)
x = -(e/d) * y + (f/d)
print("%.3f %.3f" % (x, y)) |
s093287708 | p00004 | u319774425 | 1507703875 | Python | Python | py | Runtime Error | 0 | 0 | 352 | import sys
a = []
for line in sys.stdin:
a.append(str(line))
for i in line:
b = i.split()
b = map(float, b)
b_a = b[0]
b_d = b[3]
tmp_for_calc = b_a/b_d
b_e = b[4] * tmp_for_calc
b_f = b[5] * tmp_for_calc
x = (b[2] - b_f)/(b[1] - b_e)
y = (b[2] - b[1] * x)/b[0]
print round(x, 3)
print round(y, 3) |
s873111421 | p00004 | u319774425 | 1507704465 | Python | Python | py | Runtime Error | 0 | 0 | 580 |
def get_input():
while True:
try:
yield ''.join(raw_input())
except EOFError:
break
if __name__ == '__main__':
a = list(get_input()) # [a1, a2, a3, ...]
for i in a:
b = i.split()
b = map(float, b)
b_a = b[0]
b_b = b[1]
b_c = b[2]
b_d = b[3]
b_e - b[4]
b_f = b[5]
b_d = b_a
b_e = b_a/b_d * b_e
b_f = b_a/b_d * b_f
x = (b_c - b_f)/(b_b - b_e)
y = (b_c - x * b_b)/b_a
print round(x, 3)
print round(y, 3) |
s990991912 | p00004 | u319774425 | 1507705086 | Python | Python | py | Runtime Error | 0 | 0 | 455 | import fileinput
if __name__ == '__main__':
for i in fileinput.input():
a.append(i)
for i in a:
b = i.split()
b = map(float, b)
b_a = b[0]
b_b = b[1]
b_c = b[2]
b_d = b[3]
b_e - b[4]
b_f = b[5]
b_d = b_a
b_e = b_a/b_d * b_e
b_f = b_a/b_d * b_f
x = (b_c - b_f)/(b_b - b_e)
y = (b_c - x * b_b)/b_a
print round(x, 3) |
s773099618 | p00004 | u319774425 | 1507705126 | Python | Python | py | Runtime Error | 0 | 0 | 481 | import fileinput
if __name__ == '__main__':
for i in fileinput.input():
a.append(i)
for i in a:
b = i.split()
b = map(float, b)
b_a = b[0]
b_b = b[1]
b_c = b[2]
b_d = b[3]
b_e - b[4]
b_f = b[5]
b_d = b_a
b_e = b_a/b_d * b_e
b_f = b_a/b_d * b_f
x = (b_c - b_f)/(b_b - b_e)
y = (b_c - x * b_b)/b_a
print round(x, 3)
print round(y, 3) |
s664047998 | p00004 | u422087503 | 1508709484 | Python | Python3 | py | Runtime Error | 0 | 0 | 386 | import sys
def gcd(a,b):
while True:
a, b = b, a%b
if b==0:
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())
m1 = lcm(b,e)/b
m2 = lcm(b,e)/e
x_ = a*m1-d*m2
z_ = c*m1-f*m2
x_new = z_/x_
m1 = lcm(a,d)/a
m2 = lcm(a,d)/d
y_ = b*m1-e*m2
z_ = c*m1-f*m2
y_new = z_/y_
print("{:.3f} {:.3f}".format(x_new,y_new)) |
s255605874 | p00004 | u422087503 | 1508794408 | Python | Python3 | py | Runtime Error | 0 | 0 | 387 | 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)) |
s388587367 | p00004 | u926657458 | 1508957561 | Python | Python3 | py | Runtime Error | 0 | 0 | 254 | 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() |
s003161692 | p00004 | u424041287 | 1509099597 | Python | Python3 | py | Runtime Error | 0 | 0 | 234 | t = 0
while t == 0:
try:
a,b,c,d,e,f = [int(i) for i in input().split()]t = 0
except:
break
else:
x = (e*c - b*f) / (a*e - b*d)
y = (a*f - c*d) / (a*e - b*d)
print(???{0:.3f}".format(x) + ??? ??? + ???{0:.3f}".format(y)) |
s750698870 | p00004 | u424041287 | 1509099623 | Python | Python3 | py | Runtime Error | 0 | 0 | 229 | t = 0
while t == 0:
try:
a,b,c,d,e,f = [int(i) for i in input().split()]
except:
break
else:
x = (e*c - b*f) / (a*e - b*d)
y = (a*f - c*d) / (a*e - b*d)
print(???{0:.3f}".format(x) + ??? ??? + ???{0:.3f}".format(y)) |
s754498237 | p00004 | u424041287 | 1509099647 | Python | Python3 | py | Runtime Error | 0 | 0 | 72 | t = 0
while t == 0:
a,b,c,d,e,f = [int(i) for i in input().split()]
|
s415687906 | p00004 | u424041287 | 1509099762 | Python | Python3 | py | Runtime Error | 0 | 0 | 229 | t = 0
while t == 0:
try:
a,b,c,d,e,f = [int(i) for i in input().split()]
except:
break
else:
x = (e*c - b*f) / (a*e - b*d)
y = (a*f - c*d) / (a*e - b*d)
print(???{0:.3f}".format(x) + ??? ??? + ???{0:.3f}".format(y)) |
s961452792 | p00004 | u424041287 | 1509101112 | Python | Python3 | py | Runtime Error | 0 | 0 | 229 | 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)
y = (a*f - c*e) / (a*d - b*c)
print(???{0:.3f}".format(x) + ??? ??? + ???{0:.3f}".format(y)) |
s178553333 | p00004 | u123686770 | 1509511080 | Python | Python | py | Runtime Error | 0 | 0 | 208 | while True:
data = raw_input()
if not data:
break
a,b,c,d,e,f = map(int, data.split())
x = ( e*c - b*f ) / ( b*d - a*c )
y = ( c - a*x ) / b
print "%.3f %.3f" % ( round(x,3), round(y,3) ) |
s870887665 | p00004 | u223481558 | 1509966609 | Python | Python3 | py | Runtime Error | 0 | 0 | 254 | 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('%.3lf %.3lf' % (x,y))
except:
break
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.