Problem:


Distance

  Write a program which calculates the distance between two points P1(x1, y1) and P2(x2, y2).

Input

  Four real numbers x1, y1, x2 and y2 are given in a line.

Output

  Print the distance in real number. The output should not contain an absolute error greater than 10-4.

Sample Input

0 0 1 1

Sample Output

1.41421356



Sample input:
0 0 1 1


Sample output:
1.41421356

Submission status: Accepted

Solution code:
'''
ITP-1_10-A
 ?????¢
?????? P1(x1, y1), P2(x2, y2) ????????¢????±???????????????°????????????????????????
???Input
x1, y1, x2, y2 ????????°???????????????????????§?????????????????????
???Output
P1??¨P2????????¢????????°??§?????????????????????????????????0.0001??\????????????????????£????????????????????¨????????????
'''
# # import
# import numpy
# 
# # inputData
# Data = input().split()
# x1 = int(Data[0])
# y1 = int(Data[1])
# x2 = int(Data[2])
# y2 = int(Data[3])
# 
# P1 = numpy.array([x1, y1])
# P2 = numpy.array([x2, y2])
# print(numpy.linalg.norm(P2 - P1))

import math

def get_distance(x1, y1, x2, y2):
    d = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)
    return d

if __name__ == '__main__':
    # inputData
    Data = input().split()
    x1 = float(Data[0])
    y1 = float(Data[1])
    x2 = float(Data[2])
    y2 = float(Data[3])

    d = get_distance(x1, y1, x2, y2)
    print(d)

Submission status: Accepted

Solution code:
import sys
import math

def distance(x1, y1, x2, y2):
	return math.sqrt((x1 - x2)**2 + (y1 - y2)**2)	

#fin = open("test.txt", "r")
fin = sys.stdin

[x1, y1, x2, y2] = list(map(float, fin.readline().split()))

print("{0:.5f}".format(distance(x1, y1, x2, y2)))

Submission status: Accepted

Solution code:
import math
 
x1,y1,x2,y2=list(map(float,input().split()))
 
print(math.sqrt((x2-x1)**2+(y2-y1)**2))

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, input().split())

D = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)

print(D)

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = map(float, input().split())
d = math.sqrt((x1 - x2)**2 + (y1 - y2)**2)
print("{:.5f}".format(d))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,raw_input().split())
cal = math.sqrt((x1-x2)**2+(y1-y2)**2)
print  cal

Submission status: Accepted

Solution code:
import math
#1st line
pos_x1, pos_y1, pos_x2, pos_y2 = map(float,input().split(" "))

dist = math.sqrt((pos_x1-pos_x2)**2 + (pos_y1 - pos_y2)**2)
print(str(dist))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = map(float,input().split())
print(math.sqrt((x1-x2)**2+(y1-y2)**2))

Submission status: Accepted

Solution code:
from math import sqrt
a,b,c,d = map(float,input().split())
print(sqrt((c-a)**2+(d-b)**2))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())

l = math.sqrt((math.fabs(x1-x2))*(math.fabs(x1-x2))+(math.fabs(y1-y2))*(math.fabs(y1-y2)))

print('%.4f'% l)

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = [float(i) for i in input().split()]
print(math.sqrt((x2 - x1) ** 2 +  (y2 - y1) ** 2))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = [float(x) for x in input().split(" ")]

print( ( (x2 - x1) ** 2  +  (y2 - y1) ** 2 ) ** (1/2) )

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = (float(i) for i in input().split())
print(math.sqrt((x2-x1)**2+(y2-y1)**2))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

import math
import sys


def dist():
    coordinates = [float(num) for num in sys.stdin.readline().split()]
    return math.hypot(coordinates[2]-coordinates[0],
                      coordinates[3]-coordinates[1])


def main():
    print(dist())


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
from math import sqrt
x1, y1, x2, y2 = map(float, input().split())
print(sqrt((x2-x1)**2 + (y2-y1)**2))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, input().split())
d = ((x1-x2)**2 + (y1-y2)**2)**0.5
print("{:.6f}".format(d))

Submission status: Accepted

Solution code:
a, b, c, d = [float(temp) for temp in input().split()]
from math import sqrt
dis = sqrt((c - a) ** 2 + (d - b) ** 2)
print('%0.5f'%dis)

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = map(float,(input().split()))
print("{0}".format(((x1 - x2)**2 + (y1 - y2)**2)**(1/2)))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

import sys
import os
import math


x1, y1, x2, y2 = list(map(float, input().split()))
x_diff = x1 - x2
y_diff = y1 - y2
d = math.sqrt(x_diff ** 2 + y_diff ** 2)
print(d)

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = list(map(float, input().split()))

exp_dist = abs(x1 - x2)**2 + abs(y1 - y2)**2

print(math.sqrt(exp_dist))

Submission status: Accepted

Solution code:
import math

x1,y1,x2,y2 = map(float, input().split())
dist = math.sqrt( (x2-x1)**2 + (y2-y1)**2 )
print(dist)

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, input().split())
distance = math.sqrt((x2-x1)**2 + (y2-y1)**2)
print(distance)

Submission status: Accepted

Solution code:
# coding: utf-8
# Here your code !
import sys
import collections
import math
import unittest

def calculate_distance():
    try:
        [x1, y1, x2, y2] = [float(value) for value in input().rstrip().split()]
    except:
        __input_error()
    
    print(math.hypot(x1-x2, y1-y2))

def __input_error():
    print("input error")
    return -1

class __TestValueClass(unittest.TestCase):
    def testEqual(self,func,tuples):
        self.testFunction(self.assertEqual,func,tuples)
    
    def testFunction(self,assertfunc,func,tuples):
        #tuples[index] = ([*arguments of func], compared value)
        for item in tuples:
            try:
                if isinstance(item[0], collections.Iterable):
                    assertfunc(func(*item[0]),item[1])
                else:
                    assertfunc(func(item[0]),item[1])
            except Exception as msg:
                swidth = 15
                print("="*50)
                print("-- Assertion Error in '" + func.__name__ + "' --")
                print("arguments".ljust(swidth)+":",item[0])
                print("compared value".ljust(swidth)+":",item[1])
                print("message".ljust(swidth)+":")
                print(msg)
                sys.exit()
        print(func.__name__,": succeeded")
        
#test
if __name__ == "__main__" :

    calculate_distance()
#    test = __TestValueClass()

Submission status: Accepted

Solution code:
from math import sqrt
x1, y1, x2, y2 = [float(i) for i in input().split(" ")]
print("{:.8f}".format(sqrt( (x2 -x1) ** 2 + (y2 - y1) ** 2)))

Submission status: Accepted

Solution code:
#!/usr/bin/env python

def sqroot(n):
    x = 1
    for i in range(100):
        x = (x + n/x)/2
    return x

x1, y1, x2, y2 = input().split()
x1 = float(x1)
x2 = float(x2)
y1 = float(y1)
y2 = float(y2)

distance = sqroot((x2 - x1)*(x2 - x1) + (y2 - y1)*(y2 - y1))

print("%.8f" % distance)

Submission status: Accepted

Solution code:
#ITP1_10-A Distance
x1,y1,x2,y2 = input().split(" ")
x1=float(x1)
y1=float(y1)
x2=float(x2)
y2=float(y2)
print ( ((x1-x2)**2.0 + (y1-y2)**2.0 )**0.5)

Submission status: Accepted

Solution code:
x1,y1,x2,y2=map(lambda x:float(x),input().split(" "))
print(((x1-x2)**2.0+(y1-y2)**2.0)**0.5)

Submission status: Accepted

Solution code:
x1, x2, y1, y2 = map(float, input().split())
ans = ((x1 - y1)**2 + (x2 - y2)**2)**0.5
print("{:.5f}".format(ans))

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, input().split(' '))

print('{:.5f}'.format(math.sqrt((x2-x1)**2+(y2-y1)**2)))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 =map(float, input().split())

length = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)
print("{0:04f}".format(length))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print(math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print(math.sqrt((x2 - x1)**2 + (y2 - y1)**2))

Submission status: Accepted

Solution code:
a,b,c,d = map(float,input().split())
print(abs(complex(c-a,d-b)))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = map(float,input().split())
print(math.hypot(x2-x1,y2-y1))

Submission status: Accepted

Solution code:
import math
s = input().split(" ")
n = list(map(float,s))
d = math.sqrt((n[0]-n[2])**2 + (n[1]-n[3])**2)
print(d)

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2=map(float, input().split())
print("{0:.8f}".format(math.sqrt((x2-x1)**2+(y2-y1)**2)))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
distance = math.sqrt((x2 - x1)**2 + (y2 - y1)**2)
print(distance)

Submission status: Accepted

Solution code:
x1,y1,x2,y2=map(float,input().split())
print("%.6f"%((x2-x1)**2+(y2-y1)**2)**0.5)

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, input().split())
print('{:.5f}'.format(math.sqrt(math.pow(x2 - x1, 2) + math.pow(y2 - y1, 2))))

Submission status: Accepted

Solution code:
import math
m=[float(i)for i in input().split()]
x=m[2]-m[0]
y=m[3]-m[1]
print(math.sqrt(float(x*x+y*y)))

Submission status: Accepted

Solution code:
import math

l = map(float, raw_input().split())
dist = math.sqrt((l[0] - l[2])**2 + (l[1] - l[3])**2)
print dist

Submission status: Accepted

Solution code:
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
?????¢
"""
import math
x1, y1, x2, y2 = map(float,input().strip().split())
x = x1 - x2
y = y1 - y2

distance = math.sqrt(x * x + y * y)

print(distance)

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = [float(s) for s in input().split(' ')]

print(((x1-x2)**2 + (y1-y2)**2)**0.5)

Submission status: Accepted

Solution code:
import math

def main():
    X1, Y1, X2, Y2 = map(float, input().split())

    dist = math.sqrt((X2 - X1) ** 2 + (Y2 - Y1) ** 2)
    print(dist)

main()

Submission status: Accepted

Solution code:
import math

x1,y1,x2,y2= map(float,(input().split()))

D=(x2-x1)**2+(y2-y1)**2
d= math.sqrt(D)
print(d)

Submission status: Accepted

Solution code:
x1,y1,x2,y2=list(map(float,input().split()))

d=((x1-x2)**2+(y1-y2)**2)**0.5

print(d)

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
x = x2 - x1
y = y2 - y1

result = x**2 + y**2
print(math.sqrt(result))

Submission status: Accepted

Solution code:
import math

x1,y1,x2,y2=map(float,input().split())
answer=(math.sqrt((x2-x1)**2+(y2-y1)**2))
print("{0:.8f}".format(answer))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = (float(x) for x in input().split())
print("{:.7f}".format(((x1 - x2) ** 2 + (y1 - y2) ** 2) ** 0.5))

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = list(map(float, input().split()))
d = math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)
print("{:.5f}".format(d))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())
xx = (x2-x1)**2
yy = (y2-y1)**2
print(math.sqrt(xx + yy))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())
x2=x2-x1
y2=y2-y1
x1,y1=0,0
dis=(x2**2+y2**2)
print(math.sqrt(dis))

Submission status: Accepted

Solution code:
# Aizu Problem ITP_1_10_A: Distance
#
import sys, math, os

# read input:
PYDEV = os.environ.get('PYDEV')
if PYDEV=="True":
    sys.stdin = open("sample-input.txt", "rt")


x1, y1, x2, y2 = [float(_) for _ in input().split()]
print("%.8f" % math.sqrt((x1 - x2)**2 + (y1 - y2)**2))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, raw_input().split())
x, y = x2 - x1, y2 - y1
print math.sqrt(x**2 + y**2)

Submission status: Accepted

Solution code:
x=list(map(float,input().split()))
x1,y1,x2,y2=x[0],x[1],x[2],x[3]
print(((x1-x2)**2 + (y1-y2)**2)**0.5)

Submission status: Accepted

Solution code:
a,b,c,d=map(float,input().split())
z=((a-c)**2+(b-d)**2)**(1/2)
print(z)

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
distance = math.sqrt((x1-x2)**2 + (y1-y2)**2)
print(distance)

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
distance = math.sqrt((x2-x1)**2 + (y2-y1)**2)
print(distance)

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = list(map(float, input().split()))
dist = (((x1 - x2)**2 + (y1 - y2)**2)**(1/2))
print("{:.6f}".format(dist))

Submission status: Accepted

Solution code:
from math import hypot

x1, y1, x2, y2 = list(map(float, input().split()))

print("{:.8f}".format(hypot(x2-x1, y2-y1)))

Submission status: Accepted

Solution code:
import math
xa,ya,xb,yb=map(float, input().split())
print("{0:.8f}".format(math.sqrt( (xa-xb)**2 + (ya-yb)**2 )))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=input().split()
x1=float(x1)
y1=float(y1)
x2=float(x2)
y2=float(y2)
r=math.sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2))
print(r)

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print('%f' %(math.sqrt((x1-x2)**2 + (y1-y2)**2)))

Submission status: Accepted

Solution code:
import math

x1,y1,x2,y2 = map(float,input().split())

print(math.sqrt((x2-x1)**2 + (y2-y1)**2))

Submission status: Accepted

Solution code:
import math

str = input().split(' ')
x1 = float(str[0])
x2 = float(str[1])
y1 = float(str[2])
y2 = float(str[3])

result = (x1-y1)*(x1-y1) + (x2-y2)*(x2-y2)
result = math.sqrt(result) if result != 0 else 0

print('%.6f'%result)

Submission status: Accepted

Solution code:
data = map(float, raw_input().split())
x1 = data[0]
y1 = data[1]
x2 = data[2]
y2 = data[3]

distance = ((x1 - x2)**2 + (y1 - y2)**2)**0.5
print("{:.8f}".format(distance))

Submission status: Accepted

Solution code:
import math
def main():
    x1, y1, x2, y2 = map(float, input().split())
    b = abs(x2 - x1)
    h = abs(y2 - y1)
    d = math.sqrt(b ** 2 + h ** 2)
    print("{0:.8f}".format(d))


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, raw_input().split())
print round(math.sqrt((x1 - x2)**2 + (y1 - y2)**2), 5 )

Submission status: Accepted

Solution code:
a,b,c,d=list(map(float,input().split()))
print('%.5f'%(((c-a)**2+(b-d)**2)**.5))

Submission status: Accepted

Solution code:
from math import sqrt

def main():

    x1, y1, x2, y2 = map(float, input().split())
    print(sqrt(abs(x2-x1)**2 + abs(y2-y1)**2))


main()

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = map(float, input().split())
print(math.sqrt(pow(x2-x1, 2) + pow(y2-y1, 2)))

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = [float(s) for s in input().split()]
print(math.sqrt((math.fabs(x1 - x2) ** 2) + (math.fabs(y1 - y2) ** 2)))

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = map(float, input().split())
print( ((x1-x2)**2 + (y1-y2)**2) **0.5 )

Submission status: Accepted

Solution code:
# -*-coding:utf-8

import math

def main():

    x1, y1, x2, y2 = map(float, input().split())

    print(math.sqrt(pow(x2-x1, 2) + pow(y2-y1, 2)))

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
x1,y1,x2,y2=map(float,input().split())
print(float((abs(x1-x2)**2)+abs(y1-y2)**2)**(1/2))

Submission status: Accepted

Solution code:
v,w,x,y=map(float,input().split())
print(float((abs(v-x)**2)+abs(w-y)**2)**(1/2))

Submission status: Accepted

Solution code:
a, b, c, d = map(float, input().split())                                    
print(pow((c - a)**2 + (d - b)**2, 0.5))

Submission status: Accepted

Solution code:
import math


def main():
    x1, y1, x2, y2 = map(float, input().split())

    ans = math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)
    print(ans)

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a,b,c,d=map(float,input().split())
print(((a-c)**2+(b-d)**2)**0.5)

Submission status: Accepted

Solution code:
import math
l = input().split()
x1 = float(l[0])
y1 = float(l[1])
x2 = float(l[2])
y2 = float(l[3])

a = pow((x2 - x1), 2) + pow((y2 - y1), 2)
ans = math.sqrt(a)
print(ans)

Submission status: Accepted

Solution code:
o,p,q,r = [float(i) for i in input().split()]
print(format(((q-o)**2+(r-p)**2)**(1/2), '.8f'))

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = map(float,input().split())
distance = ( (x1 - x2)**2 + (y1 - y2)**2 )**(1/2) 
print('{}'.format(distance))

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, input().split())

print(math.sqrt(math.pow(x2 - x1, 2) + math.pow(y2 - y1, 2)))

Submission status: Accepted

Solution code:
from math import *
x1, y1, x2, y2 = map(float, input().split())
print(hypot(x1 - x2, y1 - y2))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
z = math.sqrt((x1-x2)**2 + (y1-y2)**2)
print(z)

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, input().split())
print(((x1 - x2) ** 2 + (y1 - y2) ** 2) ** 0.5)

Submission status: Accepted

Solution code:
import math
def hoge(a):
    return a * a
x1, y1, x2, y2 = map(float, input().split())
print (math.sqrt(hoge(math.fabs(x1-x2)) + hoge(math.fabs(y1-y2))))

Submission status: Accepted

Solution code:
# coding:utf-8
import math
array = map(float,raw_input().split())
x1 = array[0]
y1 = array[1]
x2 = array[2]
y2 = array[3]
answer = math.sqrt(math.pow(x2 - x1,2) + math.pow(y2 - y1,2))
print answer

Submission status: Accepted

Solution code:
data = list(map(float, input().split()))
print(((data[2]-data[0])**2+(data[3]-data[1])**2)**0.5)

Submission status: Accepted

Solution code:
from math import hypot
a, b, c, d = map(float, input().split())
print(hypot(a-c, b-d))

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = [float(x) for x in input().split()]
print(((x1-x2)**2+(y1-y2)**2)**(1/2))

Submission status: Accepted

Solution code:
#!/usr/bin/python3
# -*- coding: utf-8 -*-

import sys

x1, y1, x2, y2 = map(float, sys.stdin.readline().split())
print(round(((x2-x1)**2 + (y2-y1)**2) ** 0.5, 6))

Submission status: Accepted

Solution code:
x,y,xx,yy=map(float, input().split())
print('%5f'%((x-xx)**2+(y-yy)**2)**0.5)

Submission status: Accepted

Solution code:
import math

def distance(a, b):
    dx = abs(a[0]-b[0])
    dy = abs(a[1]-b[1])
    return math.sqrt(dx*dx + dy*dy)

if __name__ == '__main__':
    x1, y1, x2, y2 = map(float, input().split())
    print(distance((x1, y1), (x2, y2)))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print("{:4f}".format(math.sqrt((x2-x1)**2 + (y2-y1)**2)))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, input().split())
print("{:.5f}".format(((x2-x1)**2 + (y2-y1)**2)**0.5))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print("{0:f}".format(math.sqrt((x1-x2)**2.0 + (y1-y2)**2.0)))

Submission status: Accepted

Solution code:
x = list(map(float, input().split(' ')))
ans = pow((pow(x[0]-x[2], 2) + pow(x[1]-x[3], 2)), 0.5)
print("{0:.8f}".format(ans))

Submission status: Accepted

Solution code:
import math
val = str(input()).split()

numList = list(map(float, list(val)))

print(math.sqrt(((numList[2]-numList[0]) ** 2) + ((numList[3]-numList[1]) ** 2)))

Submission status: Accepted

Solution code:
import math


def distance(p1, p2):
    """returns the distance between p1 and p2

    >>> d = distance((0, 0), (1, 1))
    >>> print("{0:.5f}".format(d))
    1.41421
    """
    (x1, y1) = p1
    (x2, y2) = p2
    return math.sqrt((x2-x1)**2 + (y2-y1)**2)


def run():
    x1, y1, x2, y2 = [float(i) for i in input().split()]

    print(distance((x1, y1), (x2, y2)))


if __name__ == '__main__':
    run()

Submission status: Accepted

Solution code:
from math import sqrt
x1, y1, x2, y2 = map(float, input().split())  
 
print(sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2))

Submission status: Accepted

Solution code:
#coding: utf-8
import math

x1, y1, x2, y2 = (float(i) for i in input().split())
print(math.sqrt((x2-x1)**2+(y2-y1)**2))

Submission status: Accepted

Solution code:
n = input().strip()

x1,y1,x2,y2 = [ float(i) for i in n.split() ]

dx = abs(x1 - x2)
dy = abs(y1 - y2)

dist = ( dx**2 + dy**2) ** 0.5

print(dist)

Submission status: Accepted

Solution code:
import math
x1, x2, y1, y2 = map(float, input().split())
print(math.sqrt((y1 - x1) ** 2 + (y2 - x2) ** 2))

Submission status: Accepted

Solution code:
import math

data = input().split()
x1 = float(data[0])
x2 = float(data[2])
y1 = float(data[1])
y2 = float(data[3])
x3 = x1 - x2 if x1 > x2 else x2 - x1
y3 = y1 - y2 if y1 > y2 else y2 - y1
print("%.8f" % math.sqrt(x3 * x3 + y3 * y3))

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = map(float,input().split())
dist = ((x2-x1)**2+(y2-y1)**2)**(1/2)
print(dist)

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())
dx=abs(x1-x2)
dy=abs(y1-y2)
print(math.sqrt(dx*dx+dy*dy))

Submission status: Accepted

Solution code:
import math

x1,y1,x2,y2 = tuple(float(n) for n in input().split())
D = math.sqrt((x2-x1)**2 + (y2-y1)**2)
print("{:.8f}".format(D))

Submission status: Accepted

Solution code:
import math, re

x1, y1, x2, y2 = [float(n) for n in re.split(r"\s+", input().strip())]
print("%f" % (math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())
print(math.sqrt((x2-x1)**2+(y2-y1)**2))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
X = x1 - x2
Y = y1 - y2
print('{:.5f}'.format(math.sqrt(X * X + Y * Y)))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

import math

x1, y1, x2, y2 = map(float, input().split())
dis = math.sqrt((x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2))
print(dis)

Submission status: Accepted

Solution code:
#! python3
# distance.py

import math

x1, y1, x2, y2 = [float(x) for x in input().split(' ')]
print('%.5f'%math.sqrt(pow(x2-x1, 2) + pow(y2-y1, 2)))

Submission status: Accepted

Solution code:
a,b,c,d=map(float,input().split())
print(abs(complex(c-a,d-b)))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, input().split())
ans = ((x1 - x2)**2 + (y1 - y2)**2)**0.5
print("{0:.5f}".format(ans))

Submission status: Accepted

Solution code:
import math
a,b,c,d = map(float,input().split())
print(math.sqrt(((c-a)**2) + ((d-b)**2)))

Submission status: Accepted

Solution code:
import math
l=input().split()
x1=float(l[0])
y1=float(l[1])
x2=float(l[2])
y2=float(l[3])

A=math.sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2))
print(A)

Submission status: Accepted

Solution code:
import math

x1,x2,x3,x4 = map(float, input().split())
n = (x3 - x1)**2 + (x4 - x2)**2
ans = math.sqrt(n)
print(ans)

Submission status: Accepted

Solution code:
import math
  
def floatinput():
    a = input().split()
    for i in range(len(a)):
        a[i] = float(a[i])
    return a
     
def main():
    a = floatinput()
    x1 = a[0]; y1 = a[1]; x2 = a[2]; y2 = a[3]
    print(math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2))
     
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, raw_input().split())
print ((x1-x2)**2 + (y1-y2)**2)**0.5

Submission status: Accepted

Solution code:
from math import sqrt
x1,x2,y1,y2=map(float,input().split())
a=abs(x1-y1)**2
b=abs(x2-y2)**2
s=sqrt(a+b)
print(s)

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, input().split())
print(math.sqrt(abs(x2-x1)**2 + abs(y2-y1)**2))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print('{0:.4f}'.format(math.sqrt((x2-x1)**2 + (y2-y1)**2)))

Submission status: Accepted

Solution code:
# AOJ ITP1_10_A

import math

def floatinput():
    a = input().split()
    for i in range(len(a)):
        a[i] = float(a[i])
    return a

def main():
    data = floatinput()
    x1 = data[0]; y1 = data[1]; x2 = data[2]; y2 = data[3]
    print(math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2))

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
import math
a, b, c, d = map(float, input().split())
s1 = (a - c) * (a - c)
s2 = (b - d) * (b - d)
print("%.6f"%math.sqrt(s1+s2))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print("{0:.4f}".format(math.sqrt((x1 - x2)**2 + (y1 - y2)**2)))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
print(f"{math.sqrt((x2-x1)**2+(y2-y1)**2):0.9f}")

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
x = math.fabs(x2 - x1)
y = math.fabs(y2 - y1)
d = math.sqrt(x**2 + y**2)
print('{:.8f}'.format(d))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, input().split())
print(((y2-y1)**2 + (x2-x1)**2)**(1/2))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, input().split())
print(((x1-x2)**2 + (y1-y2)**2)**(1/2))

Submission status: Accepted

Solution code:
# Distance

points = [float(i) for i in input().rstrip().split()]
a = [points[0], points[1]]
b = [points[2], points[3]]

distanceSquare = (a[0] - b[0]) ** 2 + (a[1] - b[1]) ** 2
distance = distanceSquare ** 0.5

print(distance)

Submission status: Accepted

Solution code:
from math import sqrt
x1, y1, x2, y2 = map(float, input().split())
r = sqrt((x1 - x2)**2 + (y1 - y2)**2 )
print('{0:.5f}'.format(r))

Submission status: Accepted

Solution code:
from math import sqrt
x1, y1, x2, y2 = map(float, input().split())
r = sqrt((x1 - x2)**2 + (y1 - y2)**2 )
print(r)

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, input().split())
r = math.sqrt((x1 - x2) **2 + (y1 - y2) **2)
print(r)

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, raw_input().split())
print("%f" % (math.sqrt((x1-x2)**2+(y1-y2)**2) ,))

Submission status: Accepted

Solution code:
import sys

for line in sys.stdin:
    if len(line)>1:
        x1, y1, x2, y2 = line.strip('\n').split()
        x1, y1, x2, y2 = float(x1), float(y1), float(x2), float(y2)
        print ((x1-x2)**2+(y1-y2)**2)**0.5

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float, raw_input().split())
print ((x1-x2)**2 + (y1-y2)**2)**0.5

Submission status: Accepted

Solution code:
r=map(float,raw_input().split())
x=r[0]-r[2]
y=r[1]-r[3]
if x<0:
        x=x*-1
if y<0:
        y=y*-1
print (x**2+y**2)**0.5

Submission status: Accepted

Solution code:
from __future__ import division, print_function
from sys import stdin
from math import hypot, sqrt
x1, y1, x2, y2 = (float(s) for s in stdin.readline().split())
print('{:.4f}'.format(hypot(x1-x2, y1-y2)))

Submission status: Accepted

Solution code:
(n,m,o,p) = map(float, raw_input().split())
print ((n-o)**2 + (m-p)**2)**0.5

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, raw_input().split())
print math.sqrt((x1-x2)**2+(y1-y2)**2)

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = map(float,raw_input().split())
x = x2-x1
y = y2-y1
print math.sqrt(math.pow(x,2)+math.pow(y,2))

Submission status: Accepted

Solution code:
import math

x1, y1, x2, y2 = map(float, raw_input().split())
print math.sqrt((x2-x1)**2 + (y2-y1)**2)

Submission status: Accepted

Solution code:
import math
x,y,x2,y2 = map(float, raw_input().split())
print '%.7f' % math.sqrt((x-x2)**2 + (y-y2)**2)

Submission status: Accepted

Solution code:
from math import hypot

x1, y1, x2, y2 = map(float, input().strip().split())
print(hypot(x2 - x1, y2 - y1))

Submission status: Accepted

Solution code:
from math import sqrt 
a,b,c,d=map(float,input().split())
e=sqrt((c-a)**2+(d-b)**2)
print(e)

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = [float(x) for x in input().split()]

print(math.sqrt((x1-x2)**2+(y1-y2)**2))

Submission status: Accepted

Solution code:
a,b,c,d=map(float,input().split())

import math

x=math.sqrt((c-a)**2+(d-b)**2)

print("{:.5f}".format(x))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float, input().split())
X = x1 - x2
Y = y1 - y2
print('{:.5f}'.format(math.sqrt(X * X + Y * Y)))

Submission status: Accepted

Solution code:
x1,y1,x2,y2=map(float,input().split())
print(((x1-x2)**2+(y1-y2)**2)**0.5)

Submission status: Accepted

Solution code:
x1,y1,x2,y2=map(float,input().split())
a=(x2-x1)*(x2-x1)+(y2-y1)*(y2-y1)
print(a**(1/2))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(float,input().split())
a=((x1 - x2) ** 2 + (y1 - y2) ** 2) ** 0.5
print(a)

Submission status: Accepted

Solution code:
a,b,c,d=map(float,input().split())
r=((c-a)**2+(d-b)**2)**(1/2)
print(f'{r:5f}')

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())

l=math.sqrt((x2-x1)**2+(y2-y1)**2)

print('{:.8f}'.format(l))

Submission status: Accepted

Solution code:

a,b,c,d=map(float,input().split())

x=c-a
y=d-b

print((x**2+y**2)**(1/2))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())
dx,dy=x2-x1,y2-y1
d=math.sqrt(dx*dx+dy*dy)
print("{:.8f}".format(d))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = input().split( )
x = float(x1)-float(x2)
y = float(y1)-float(y2)
print(math.sqrt(x**2+y**2))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2 = map(float,input().split())
a = math.sqrt((x2-x1)**2+(y2-y1)**2)
print('{:.8f}'.format(a))

Submission status: Accepted

Solution code:
import math
x1, y1, x2, y2 = map(float,input().split())
a = abs(x1-x2)
b = abs(y1-y2)

print(math.sqrt(a*a+b*b))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())
print("{0:.8f}".format(math.sqrt((x1-x2)**2+(y1-y2)**2)))

Submission status: Accepted

Solution code:
a=list(map(float,input().split()))
print((abs(a[0]-a[2])**2+abs(a[1]-a[3])**2)**(1/2))

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = map(float,input().split())
an = (x1 - x2)**2 + (y1 - y2)**2
dis = an/2
v = an/4
while abs(dis**2 - an) > 0.0001:
	if dis**2 > an:
		dis -= v
	else:
		dis += v
	v = v/2
print(dis)

Submission status: Accepted

Solution code:
values=input().split()
x1=float(values[0])
y1=float(values[1])
x2=float(values[2])
y2=float(values[3])
x_distance=x2-x1
y_distance=y2-y1
print(pow(pow(x_distance,2)+pow(y_distance,2),0.5))

Submission status: Accepted

Solution code:

x1,y1,x2,y2=map(float,input().split())
import math
A=math.sqrt((x2-x1)**2+(y2-y1)**2)

B=float('{:.8f}'.format(A))
print(B)

Submission status: Accepted

Solution code:
import math
a,b,c,d=map(float,input().split())
n=(a-c)**2+(b-d)**2
print(math.sqrt(n))

Submission status: Accepted

Solution code:
import math
x1,y1,x2,y2=map(float,input().split())
dx=abs(x1-x2)
dy=abs(y1-y2)
print(math.sqrt(dx*dx+dy*dy))

Submission status: Accepted

Solution code:
import math;

x1,y1,x2,y2 = map(float,input().split());

x = (x2 - x1)**2;
y = (y2 - y1)**2;

c = math.sqrt(x + y);
print('{:.8f}'.format(c));

Submission status: Accepted

Solution code:
x1,y1,x2,y2=map(float,input().split())
import math
s=math.sqrt((x1-x2)**2+(y1-y2)**2)
print(f'{s:.08f}')

Submission status: Accepted

Solution code:
import math

px, py, qx, qy = map(float,input().split())
pq = (qx - px) ** 2 + (qy - py) ** 2

print(math.sqrt(pq))