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
s183924813
p02377
u176732165
1523420295
Python
Python
py
Runtime Error
0
0
2835
''' import numpy as np import matplotlib.pyplot as plt import seaborn as sns import pandas as pd import sys import csv import argparse import time ''' import heapq INF = sys.maxint/3 class Edge: def __init__(self, to, cap, cost, rev): self.to = to self.cap = cap self.cost = cost self.rev = rev def print_attributes(self): print "to: {0}, cap: {1}, cost: {2}, rev: {3}".format(self.to, self.cap, self.cost, self.rev) class MinimumCostFlow: def __init__(self, V, E): self.V = V self.E = E self.G = [[] for i in range(V)] def add_edge(self, s, t, cap, cost): forward_edge = Edge(t, cap, cost, len(self.G[t])) self.G[s].append(forward_edge) backward_edge = Edge(s, 0, -cost, len(self.G[s])-1) self.G[t].append(backward_edge) def print_edges(self): print "==== print edges ====" for i in range(self.V): print "\nedges from {}".format(i) for e in self.G[i]: e.print_attributes() def minimum_cost_flow(self, s, t, f): res = 0 h = [0] * self.V while f>0: pque = [] dist = [INF for i in range(self.V)] prev_v = [0 for i in range(self.V)] prev_e = [0 for i in range(self.V)] dist[s] = 0 heapq.heappush(pque, (0, s)) while(len(pque)!=0): p = heapq.heappop(pque) v = p[1] if (dist[v] < p[0]): continue for i in range(len(self.G[v])): e = self.G[v][i] if (e.cap>0 and dist[e.to] > dist[v] + e.cost + h[v] - h[e.to]): dist[e.to] = dist[v] + e.cost + h[v] - h[e.to] prev_v[e.to] = v prev_e[e.to] = i heapq.heappush(pque, (dist[e.to], e.to)) if dist[t] == INF: return -1 for v in range(self.V): h[v] += dist[v] d = f v = t while v!=s: d = min(d, self.G[prev_v[v]][prev_e[v]].cap) v = prev_v[v] f -= d res += d * h[t] v = t while v!=s: e = self.G[prev_v[v]][prev_e[v]] e.cap -= d self.G[v][e.rev].cap += d v = prev_v[v] return res def main(): V, E, F = map(int, raw_input().split()) mcf = MinimumCostFlow(V, E) for i in range(E): u, v, c, d = map(int, raw_input().split()) mcf.add_edge(u, v, c, d) #print "minimum cost flow: {}".format(mcf.minimum_cost_flow(0, V-1, F)) print mcf.minimum_cost_flow(0, V-1, F) if __name__ == '__main__': main()
s568441789
p02378
u798803522
1508342093
Python
Python3
py
Runtime Error
0
0
704
a_num, b_num, e_num = (int(n) for n in input().split(" ")) connect = defaultdict(list) all_v = a_num + b_num match = [0 for n in range(all_v)] used = [0 for n in range(all_v)] for _ in range(e_num): v1, v2 = (int(n) for n in input().split(" ")) v2 += a_num + 1 connect[v1].append(v2) connect[v2].append(v1) def dfs(here,used,match,connect): used[here] = 1 for near in connect[here]: if not match[near] or (not used[near] and dfs(near,used,match,connect)): match[here] = near match[near] = here return 1 return 0 answer = 0 for i in range(all_v): if not match[i] and dfs(i,used,match,connect): answer += 1 print(answer)
s334315074
p02378
u798803522
1508343511
Python
Python3
py
Runtime Error
0
0
799
from collections import defaultdict a_num, b_num, e_num = (int(n) for n in input().split(" ")) connect = defaultdict(list) all_v = a_num + b_num match = [0 for n in range(all_v)] for _ in range(e_num): v1, v2 = (int(n) for n in input().split(" ")) v2 += a_num + 1 connect[v1].append(v2) connect[v2].append(v1) def dfs(here,used,match,connect): used[here] = 1 for near in connect[here]: m = match[near] if m < 0 or (not used[m] and dfs(m,used,match,connect)): match[here] = near match[near] = here return 1 return 0 answer = 0 for i in range(all_v): if match[i] < 0: if dfs(i,used,match,connect): used = [0 for n in range(all_v)] answer += 1 print(answer)
s832476567
p02378
u798803522
1508343873
Python
Python3
py
Runtime Error
0
0
768
from collections import defaultdict def dfs(here,used,match,connect): used[here] = 1 for near in connect[here]: m = match[near] if m < 0 or (not used[m] and dfs(m,used,match,connect)): match[here] = near match[near] = here return 1 return 0 a_num, b_num, e_num = (int(n) for n in input().split(" ")) connect = defaultdict(list) all_v = a_num + b_num match = [-1 for n in range(all_v)] for _ in range(e_num): v1, v2 = (int(n) for n in input().split(" ")) v2 += a_num connect[v1].append(v2) connect[v2].append(v1) answer = 0 for i in range(all_v): if match[i] < 0: if dfs(i,used,match,connect): used = [0 for n in range(all_v)] answer += 1 print(answer)
s957611737
p02378
u798803522
1508343913
Python
Python3
py
Runtime Error
0
0
768
from collections import defaultdict def dfs(here,used,match,connect): used[here] = 1 for near in connect[here]: m = match[near] if m < 0 or (not used[m] and dfs(m,used,match,connect)): match[here] = near match[near] = here return 1 return 0 a_num, b_num, e_num = (int(n) for n in input().split(" ")) connect = defaultdict(list) all_v = a_num + b_num match = [-1 for n in range(all_v)] for _ in range(e_num): v1, v2 = (int(n) for n in input().split(" ")) v2 += a_num connect[v1].append(v2) connect[v2].append(v1) answer = 0 for i in range(all_v): if match[i] < 0: if dfs(i,used,match,connect): used = [0 for n in range(all_v)] answer += 1 print(answer)
s521077832
p02379
u400765446
1531154777
Python
Python3
py
Runtime Error
0
0
157
from math import sqrt def main(): x1, y1, x2, y2 = map(float, input()) print(sqrt((x2-x1)**2 + (y2-y1)**2)) if __name__ == '__main__': main()
s993468085
p02379
u539753516
1531429233
Python
Python3
py
Runtime Error
0
0
68
a,b,c,d=map(int,input().split()) print((((a-c)**2)+((b-d)**2))**.5)
s846707439
p02379
u749884951
1534848999
Python
Python3
py
Runtime Error
0
0
97
import math x1, y1, x2, y2 = map(int, input().split()) print(math.sqrt((x1-x2)**2 + (y1-y2)**2))
s482537232
p02379
u749884951
1534849040
Python
Python3
py
Runtime Error
0
0
97
import math x1, y1, x2, y2 = map(int, input().split()) print(math.sqrt((x1-x2)**2 + (y1-y2)**2))
s175625470
p02379
u336705996
1535367410
Python
Python3
py
Runtime Error
0
0
92
import math x1,y1,x2,y2 = map(int,input().split()) print(math.sqrt((x2-x1)**2+(y2-y1)**2))
s028781354
p02379
u336705996
1535367688
Python
Python3
py
Runtime Error
0
0
110
import math x1,y1,x2,y2 = map(int,input().split()) print('{0:.5f}'.format(math.sqrt((x2-x1)**2+(y2-y1)**2)))
s681610167
p02379
u317583692
1535495153
Python
Python3
py
Runtime Error
0
0
100
import math x_1,y_1,x_2,y_2 = int(input().split(" ")) print(math.sqrt((x_1-x_2)**2+(y_1-y_2)**2))
s018797944
p02379
u317583692
1535495228
Python
Python3
py
Runtime Error
0
0
99
import math x_1,y_1,x_2,y_2 = map(int,input().split()) print(math.sqrt((x_1-x_2)**2+(y_1-y_2)**2))
s031461019
p02379
u281808376
1540513076
Python
Python3
py
Runtime Error
0
0
161
lst=input().split() lst_i=list(map(lambda i : int(i),lst)) x_1=lst_i[0] y_1=lst_i[1] x_2=lst_i[2] y_2=lst_i[3] dis=((x_1-y_1)**2+(x_2-y_2)**2)**(1/2) print(dis)
s921480765
p02379
u281808376
1540513217
Python
Python3
py
Runtime Error
0
0
134
lst=input().split() x_1=int(lst[0]) y_1=int(lst[1]) x_2=int(lst[2]) y_2=int(lst[3]) dis=((x_1-y_1)**2+(x_2-y_2)**2)**(1/2) print(dis)
s204954168
p02379
u281808376
1540513265
Python
Python3
py
Runtime Error
0
0
129
lst=input().split() x_1=lst[0] y_1=int(lst[1]) x_2=int(lst[2]) y_2=int(lst[3]) dis=((x_1-y_1)**2+(x_2-y_2)**2)**(1/2) print(dis)
s029057121
p02379
u281808376
1540513285
Python
Python3
py
Runtime Error
0
0
114
lst=input().split() x_1=lst[0] y_1=lst[1] x_2=lst[2] y_2=lst[3] dis=((x_1-y_1)**2+(x_2-y_2)**2)**(1/2) print(dis)
s329310791
p02379
u281808376
1540513689
Python
Python3
py
Runtime Error
0
0
135
lst=input().split() x_1=int(lst[0]) y_1=int(lst[1]) x_2=int(lst[2]) y_2=int(lst[3]) dis=((x_1-x_2)**2+(y_1-y_2)**2)**(1/2) print(dis)
s710363958
p02379
u281808376
1540513880
Python
Python3
py
Runtime Error
0
0
115
lst=input().split() x_1=lst[0] y_1=lst[1] x_2=lst[2] y_2=lst[3] dis=((x_1-x_2)**2+(y_1-y_2)**2)**(1/2) print(dis)
s011177415
p02379
u281808376
1540514044
Python
Python3
py
Runtime Error
0
0
150
lst=input().split() lst=list(map(lambda i:int(i),lst)) x_1=lst[0] x_2=lst[1] y_1=lst[2] y_2=lst[3] dis=((x_1-x_2)**2+(y_1-y_2)**2)**(1/2) print(dis)
s854499480
p02379
u281808376
1540514703
Python
Python3
py
Runtime Error
0
0
35
lst=input().split() x=int(lst[0])
s001712497
p02379
u281808376
1540514800
Python
Python3
py
Runtime Error
0
0
169
lst=input().split() lst=list(map(lambda i:float(i),lst)) x_1=lst[0] x_2=lst[1] y_1=lst[2] y_2=lst[3] dis=((x_1-x_2)**2+(y_1-y_2)**2)**(1/2) print("{.:8}".format(dis))
s655890411
p02379
u198574985
1545386522
Python
Python3
py
Runtime Error
0
0
162
import math x1,y1,x2,y2 = map(int,input().split()) x_dis = abs(x1-x2) y_dis = abs(y1-y2) hypo = math.sqrt(x_dis**2 + y_dis**2) dis = round(hypo,8) print(dis)
s651351573
p02379
u088337682
1545626231
Python
Python3
py
Runtime Error
0
0
75
x1,y1,x2,y2 = map(int,input().split()) print(((x1-x2)**2+(y1-y2)**2)**0.5)
s851841408
p02379
u879471116
1546268484
Python
Python3
py
Runtime Error
0
0
96
x1, y1, x2, y2 = map(int, input().split()) print('%.8f' % (((x2 - x1)**2 + (y2 - y1)**2))**0.5)
s488112709
p02379
u096070545
1546395465
Python
Python3
py
Runtime Error
0
0
164
# coding: utf-8 # Your code here! import math x1, y1, x2, y2 = map(int, input().split()) result = math.sqrt( (x2-x1) * (x2-x1) + (y2-y1) * (y2-y1) ) print(result)
s299484979
p02379
u221724886
1556086160
Python
Python3
py
Runtime Error
0
0
170
# -*- coding: utf-8 -*- # ITP1_10_A import math pos = list(map(int, input().split())) x = abs(pos[2] - pos[0]) y = abs(pos[3] - pos[1]) print(math.sqrt(x**2 + y**2))
s132092335
p02379
u083560765
1556195334
Python
Python3
py
Runtime Error
0
0
104
import math n=input().split() x=int(n[2])-int(n[0]) y=int(n[3])-int(n[1]) print(math.sqrt(x**2+y**2))
s914398254
p02379
u928633434
1556623953
Python
Python3
py
Runtime Error
0
0
115
import math x1,y1,x2,y2 = (float(x) for x in input().split()) d = math.sqrt((x2 - x1)^2 + (y2 - y1)^2) print (d)
s477190987
p02379
u928633434
1556623985
Python
Python3
py
Runtime Error
0
0
119
import math x1,y1,x2,y2 = (float(x) for x in input().split()) d = math.sqrt((x2 - x1)^2.0 + (y2 - y1)^2.0) print (d)
s259166206
p02379
u805716376
1556728080
Python
Python3
py
Runtime Error
0
0
104
import math x1, y1, x2, y2 = map(int, input().split()) print(f'{math.sqrt((x2-x1)**2+(y2-y1)**2):.8f}')
s084074754
p02379
u805716376
1556728157
Python
Python3
py
Runtime Error
0
0
104
import math x1, y1, x2, y2 = map(int, input().split()) print(f'{math.sqrt((x2-x1)**2+(y2-y1)**2):.8f}')
s747737922
p02379
u025362139
1556812864
Python
Python3
py
Runtime Error
0
0
123
#coding: UTF-8 import math p = list(map(int, input().split())) dis = math.sqrt((p[2] - p[0]) + (p[3] - p[1])) print(dis)
s058250350
p02379
u025362139
1556814067
Python
Python3
py
Runtime Error
0
0
160
#coding: UTF-8 import math p = list(map(float, input().split())) dis = math.sqrt((abs(p[2]) - abs(p[0]))^2 + (abs(p[3]) - abs(p[1]))^2) print(round(dis, 8))
s823444148
p02379
u876889037
1559175756
Python
Python3
py
Runtime Error
0
0
313
import math class Point(): def __init__(self, x, y): self.x = x self.y = y x1, y1, x2, y2 = [int(i) for i in input().split()] point1 = Point(x1, y1) point2 = Point(x2, y2) x_dist = point1.x - point2.x y_dist = point1.y - point2.y dist = math.sqrt(x_dist ** 2 + y_dist ** 2) print(dist)
s081675055
p02379
u535719732
1559307056
Python
Python3
py
Runtime Error
0
0
126
import math data = list(map(int,input().split())) print("%f" %(math.sqrt(abs(data[0]-data[2])**2 + abs(data[1]-data[3]**2))))
s878257775
p02379
u800408401
1559539508
Python
Python3
py
Runtime Error
0
0
81
x1,y1,x2,y2=map(int,input().split()) d=((x1-x2)**2 + (y1-y2)**2)**(1/2) print(d)
s702271852
p02379
u800408401
1559539516
Python
Python3
py
Runtime Error
0
0
81
x1,y1,x2,y2=map(int,input().split()) d=((x1-x2)**2 + (y1-y2)**2)**(1/2) print(d)
s700791016
p02379
u140201022
1413130723
Python
Python
py
Runtime Error
0
0
79
x1,y1,x2,y2=map(int,raw_input().split()) x=x2-x1 y=y2-y1 print (x**2+y**2)**0.5
s406868100
p02379
u507118101
1416224986
Python
Python
py
Runtime Error
0
0
134
import math x1,y1,x2,y2 = map(int,raw_input().split(' ')) x = abs(x1 - x2); y = abs(y1 - y2); a = y/math.sin(math.radians(45)) print a
s296694632
p02379
u567380442
1421193521
Python
Python3
py
Runtime Error
0
0
106
import math x1, y1, x2, y2 = map(int, input().split()) print(math.sqrt(pow(x1 - x2, 2) + pow(y1 - y2, 2)))
s156885137
p02379
u567380442
1421193750
Python
Python3
py
Runtime Error
0
0
92
x1, y1, x2, y2 = map(int, input().split()) print((pow(x1 - x2, 2) + pow(y1 - y2, 2)) ** 0.5)
s400020588
p02379
u567380442
1421193819
Python
Python3
py
Runtime Error
0
0
90
x1, y1, x2, y2 = map(int, input().split()) print(((x1 - x2) ** 2 + (y1 - y2) ** 2) ** 0.5)
s042182464
p02379
u839573768
1423385316
Python
Python
py
Runtime Error
0
0
132
from math import * x1, y1, x2, y2 = map(int, raw_input().split()) distance = sqrt((x1-x2)*(x1-x2) + (y1-y2)*(y1-y2)) print distance
s377867741
p02379
u067975558
1423532987
Python
Python3
py
Runtime Error
0
0
185
import math (x1, y1, x2, y2) = int(input().split()) #distance = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2) distance - math.hypot((x2 - x1), (y2 - y1)) print('{0:.5f}'.format(distance))
s043834212
p02379
u823030818
1423533034
Python
Python3
py
Runtime Error
0
0
155
import math (x1, y1, x2, y2) = [float(i) for i in input().split()] distance = math.sqrt((x2 - x1) ** 2 + (y2 - u1) ** 2) print('{0:.5f}'.format(distance))
s624881812
p02379
u067975558
1423533041
Python
Python3
py
Runtime Error
0
0
200
import math (x1, y1, x2, y2) = [float(i) for i in input().split()] #distance = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2) distance - math.hypot((x2 - x1), (y2 - y1)) print('{0:.5f}'.format(distance))
s953858748
p02379
u492556875
1424619105
Python
Python3
py
Runtime Error
0
0
144
import sys import math (x1, y1, x2, y2) = [int(i) for i in sys.stdin.readline().split()] d = math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2) print(d)
s898576744
p02379
u949338836
1428652577
Python
Python3
py
Runtime Error
0
0
209
#coding:utf-8 #1_10_A 2015.4.10 import math position = list(map(int,input().split())) distance = math.sqrt((position[2] - position[0]) ** 2 + (position[3] - position[1]) ** 2) print('{:.5f}'.format(distance))
s728025250
p02379
u669360983
1431077833
Python
Python3
py
Runtime Error
0
0
116
import math point=list(map(int,input().split())) print(math.sqrt(pow(point[2]-point[0],2)+pow(point[3]-point[1],2)))
s350663658
p02379
u669360983
1431077859
Python
Python3
py
Runtime Error
0
0
116
import math point=list(map(int,input().split())) print(math.sqrt(pow(point[2]-point[0],2)+pow(point[3]-point[1],2)))
s320328159
p02379
u669360983
1431077890
Python
Python3
py
Runtime Error
0
0
116
import math point=list(map(int,input().split())) print(math.sqrt(pow(point[2]-point[0],2)+pow(point[3]-point[1],2)))
s895814511
p02379
u669360983
1431078019
Python
Python3
py
Runtime Error
0
0
116
import math point=list(map(int,input().split())) print(math.sqrt(pow(point[2]-point[0],2)+pow(point[3]-point[1],2)))
s076524209
p02379
u777299405
1435046574
Python
Python3
py
Runtime Error
0
0
90
x1, y1, x2, y2 = map(int, input().split()) print(((x1 - x2) ** 2 + (y1 - y2) ** 2) ** 0.5)
s383799458
p02379
u571345655
1435200805
Python
Python
py
Runtime Error
0
0
127
# coding=utf-8 from math import sqrt x1, y1, x2, y2 = map(int, raw_input().split()) print sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)
s751668648
p02379
u571345655
1435201009
Python
Python
py
Runtime Error
0
0
127
# coding=utf-8 import math.sqrt x1, y1, x2, y2 = map(int, raw_input().split()) print math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)
s927289515
p02379
u571345655
1435201016
Python
Python
py
Runtime Error
0
0
122
# coding=utf-8 import math x1, y1, x2, y2 = map(int, raw_input().split()) print math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)
s367703452
p02379
u571345655
1435201049
Python
Python
py
Runtime Error
0
0
123
# coding=utf-8 import math x1, y1, x2, y2 = map(int, raw_input().split()) print math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)
s474229080
p02379
u609407244
1436084685
Python
Python3
py
Runtime Error
0
0
90
x1, y1, x2, y2 = map(int, input().split()) print(((x1 - x2) ** 2 + (y1 - y2) ** 2) ** 0.5)
s488961088
p02379
u017764209
1438496759
Python
Python
py
Runtime Error
0
0
106
import math x1,y1,x2,y2 = raw_input().split(' ') line = math.sqrt(((x2-x1)**2)+((x2-x1)**2)) print line
s558282077
p02379
u017764209
1438497002
Python
Python
py
Runtime Error
0
0
124
import math x1,y1,x2,y2 = raw_input().split(' ') line = math.sqrt((int(x2)-int(x1)**2)+((int(y2)-int(y1))**2)) print line
s984325113
p02379
u467309160
1443585179
Python
Python3
py
Runtime Error
0
0
212
using namespace std; int main() { double x1, x2, y1, y2; cin >> x1 >> y1 >> x2 >> y2; cout << fixed << setprecision(6) << sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1)) << endl; return 0; }
s506753974
p02379
u240363515
1443626899
Python
Python
py
Runtime Error
0
0
99
import math x1, y1, x2, y2 = map(int, raw_input().split()) print math.sqrt((x2-x1)**2 + (y2-y1)**2)
s576521029
p02379
u240363515
1443628454
Python
Python
py
Runtime Error
0
0
157
x1, y1, x2, y2 = map(int, raw_input().split()) num = (x2-x1)*(x2-x1) + (y2-y1)*(y2-y1) xi = num for _ in range(100): xi = (xi + (num / xi)) / 2.0 print xi
s648702190
p02379
u240363515
1443628475
Python
Python
py
Runtime Error
0
0
156
x1, y1, x2, y2 = map(int, raw_input().split()) num = (x2-x1)*(x2-x1) + (y2-y1)*(y2-y1) xi = num for _ in range(10): xi = (xi + (num / xi)) / 2.0 print xi
s517781518
p02379
u240363515
1443628666
Python
Python
py
Runtime Error
10
6360
159
x1, y1, x2, y2 = map(float, raw_input().split()) num = (x2-x1)*(x2-x1) + (y2-y1)*(y2-y1) xi = num for _ in range(100): xi = (xi + (num / xi)) / 2.0 print xi
s430192843
p02379
u240363515
1443628684
Python
Python
py
Runtime Error
0
6396
159
x1, y1, x2, y2 = map(float, raw_input().split()) num = (x2-x1)*(x2-x1) + (y2-y1)*(y2-y1) xi = num for _ in range(100): xi = (xi + (num / xi)) / 2.0 print xi
s848370726
p02379
u072053884
1445739709
Python
Python3
py
Runtime Error
0
0
116
import math x1, y1, x2, y2 = map(int, input().split()) dx = x1 - x2 dy = y1 - y2 d = math.hypot(dx, dy) print(d)
s999642834
p02379
u636273094
1449023667
Python
Python
py
Runtime Error
0
0
147
import math p = raw_input().split() x = math.fabs(int(p[0]) - int(p[2])) y = math.fabs(int(p[1]) - int(p[3])) print '%.8f' % math.sqrt(x**2 + y**2)
s331177699
p02379
u811841526
1449088147
Python
Python3
py
Runtime Error
0
0
111
from math import sqrt x1, y1, x2, y2 = map(int, input().split()) r = sqrt((x2 - x1)**2 + (y2 - x2)**2) print(r)
s777759055
p02379
u811841526
1449088309
Python
Python3
py
Runtime Error
0
0
111
from math import sqrt x1, y1, x2, y2 = map(int, input().split()) r = sqrt((x2 - x1)**2 + (y2 - y1)**2) print(r)
s862288059
p02379
u811841526
1449088355
Python
Python3
py
Runtime Error
0
0
111
from math import sqrt x1, y1, x2, y2 = map(int, input().split()) r = sqrt((x2 - x1)**2 + (y2 - y1)**2) print(r)
s537066391
p02379
u811841526
1449088390
Python
Python3
py
Runtime Error
0
0
111
from math import sqrt x1, y1, x2, y2 = map(int, input().split()) r = sqrt((x2 - x1)**2 + (y2 - y1)**2) print(r)
s032026742
p02379
u811841526
1449088434
Python
Python3
py
Runtime Error
0
0
111
from math import sqrt x1, y1, x2, y2 = map(int, input().split()) r = sqrt((x2 - x1)**2 + (y2 - y1)**2) print(r)
s461128475
p02379
u461370825
1449755922
Python
Python
py
Runtime Error
10
6596
201
from math import * PI = 3.1415926535898 while True: try: a, b, x, y = map(float, raw_input().strip().split(' ')) print pow((a-x)*(a-x)+(b-y)*(b-y), 0.5) except EOFError: break
s734425819
p02379
u512342660
1450801149
Python
Python
py
Runtime Error
0
0
103
from math import * x1,y1,x2,y2 = map(int,raw_input().split()) print sqrt(fabs(x1-x2)**2+fabs(y1-y2)**2)
s780601165
p02379
u580607517
1451659039
Python
Python
py
Runtime Error
0
0
176
import math point = map(int, raw_input().split()) x1 = point[0] y1 = point[1] x2 = point[2] y2 = point[3] distance = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2) print distance
s715072785
p02379
u000228958
1453006098
Python
Python
py
Runtime Error
0
0
109
import math x1, y1, x2, y2 = map(int, raw_input().split()) print math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)
s678864664
p02379
u971748390
1454316717
Python
Python3
py
Runtime Error
0
0
103
imort math x1,y1,x2,y2=map(float,input().split()) d=math.sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2)) print(d)
s894045745
p02379
u971748390
1454317129
Python
Python3
py
Runtime Error
0
0
97
imort math x1,y1,x2,y2=map(float,input().split()) d=math.sqrt(pow(x1-x2,2)+pow(y1-y2,2)) print(d)
s494764316
p02379
u017764209
1454969435
Python
Python
py
Runtime Error
0
0
228
import math x1,y1,x2,y2 = raw_input().split() tei = x2 - x1 taka = y2 - y1 if tei == taka: st = math.sqrt(2) answ = st * tei print answ if tei != taka: answ = (tei*tei) + (taka*taka) print math.sqrt(answ)
s403837365
p02379
u278714855
1455176814
Python
Python
py
Runtime Error
0
0
210
#!/usr/bin/env python #coding: UTF-8 import math line = [] for l in open('text.txt', 'r'): for i in l.split(' '): line.append(float(i)) a = (line[0]-line[2])**2+(line[1]-line[3])**2 print math.sqrt(a)
s640499872
p02379
u278714855
1455176941
Python
Python
py
Runtime Error
10
6460
172
import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = (line[0]-line[2])**2+(line[1]-line[3])**2 print math.sqrt(a)
s175696066
p02379
u278714855
1455177445
Python
Python
py
Runtime Error
10
6476
190
import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = (line[0]-line[2])**2+(line[1]-line[3])**2 b = math.sqrt(a) print ('%.10f' % b)
s104087647
p02379
u278714855
1455177486
Python
Python
py
Runtime Error
10
6552
190
import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = (line[0]-line[2])**2+(line[1]-line[3])**2 b = math.sqrt(a) print ('%.20f' % b)
s077016441
p02379
u278714855
1455177560
Python
Python
py
Runtime Error
30
6488
190
import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = (line[0]-line[2])**2+(line[1]-line[3])**2 b = math.sqrt(a) print ('%.12f' % b)
s307474967
p02379
u278714855
1455177758
Python
Python
py
Runtime Error
10
6548
189
import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = (line[0]-line[2])**2+(line[1]-line[3])**2 b = math.sqrt(a) print ('%.4f' % b)
s190781670
p02379
u278714855
1455177788
Python
Python
py
Runtime Error
10
6548
191
import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = (line[0]-line[2])**2+(line[1]-line[3])**2 b = math.sqrt(a) print ('%03.4f' % b)
s355603786
p02379
u797673668
1455929329
Python
Python3
py
Runtime Error
0
0
110
from math import sqrt x1, y1, x2, y2 = map(int, input().split()) print(sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2))
s465068443
p02379
u148101999
1457602626
Python
Python
py
Runtime Error
0
0
171
#encoding=utf-8 import sys import math printf = sys.stdout.write x1,y1,x2,y2 = map(int,raw_input().split()) X = x2 - x1 Y = y2 - y1 printf(str(math.sqrt(X**2 + Y**2)))
s462707149
p02379
u867824281
1457795329
Python
Python3
py
Runtime Error
0
0
117
import math x1,y1,x2,y2 = map(int,input().split(" ")) yoko = x2 - x1 tate = y2 - y1 print(math.sqrt(yoko**2+tate**2))
s862204324
p02379
u075836834
1457873978
Python
Python3
py
Runtime Error
0
0
118
#distance import math x1,y1,x2,y2=map(int,input().split()) distance = math.sqru((x2-x1)**2+(y2-y1)**2) print(distance)
s515203441
p02379
u075836834
1457874052
Python
Python3
py
Runtime Error
0
0
118
#distance import math x1,y1,x2,y2=map(int,input().split()) distance = math.sqrt((x2-x1)**2+(y2-y1)**2) print(distance)
s279776906
p02379
u981139449
1458140575
Python
Python3
py
Runtime Error
0
0
123
from math import sqrt x1, y1, x2, y2 = (int(i) for i in input().split()) d = sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2) print(d)
s783461398
p02379
u278714855
1458539234
Python
Python
py
Runtime Error
10
6596
203
#!/usr/bin/env python #coding: UTF-8 import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) print math.sqrt((line[0]-line[2])**2+(line[1]-line[3])**2)
s821511544
p02379
u278714855
1458539651
Python
Python
py
Runtime Error
10
6596
218
#!/usr/bin/env python #coding: UTF-8 import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = math.sqrt((line[0]-line[2])**2+(line[1]-line[3])**2) print '%06.6f'%a
s626012831
p02379
u278714855
1458539694
Python
Python
py
Runtime Error
10
6544
219
#!/usr/bin/env python #coding: UTF-8 import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = math.sqrt((line[0]-line[2])**2+(line[1]-line[3])**2) print '%06.20f'%a
s690794107
p02379
u278714855
1458539758
Python
Python
py
Runtime Error
10
6548
217
#!/usr/bin/env python #coding: UTF-8 import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = math.sqrt((line[0]-line[2])**2+(line[1]-line[3])**2) print '%.12f'%a
s639679050
p02379
u278714855
1458539917
Python
Python
py
Runtime Error
30
6548
214
#!/usr/bin/env python #coding: UTF-8 import sys import math line = [] for l in sys.stdin: for i in l.split(' '): line.append(float(i)) a = math.sqrt((line[0]-line[2])**2+(line[1]-line[3])**2) print '%f'%a
s951883728
p02379
u869301406
1460358812
Python
Python
py
Runtime Error
0
0
128
import math data =map(int, raw_input().split(" ")) dx = data[2] - data[0] dy = data[3] - data[1] print math.sqrt(dx**2+dy**2)