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

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

Solution (Python):
inData = list(map(float,input().split()))
p11 = inData[0]
p12 = inData[1]
p21 = inData[2]
p22 = inData[3]

distance = pow(pow(p21-p11,2) + pow(p22-p12,2),1/2)
print(distance)

Solution (Python):

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

Solution (Python):
import math
x1, y1, x2, y2 = map(float, input().split())
def get_distance(x1, y1, x2, y2):
    d = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)
    return d
c = get_distance(x1, y1, x2, y2)
print(c)

Solution (Python):
from math import sqrt


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

rs = sqrt(abs(x1 - x2)**2 + abs(y1 - y2)**2)
print(round(rs, 8))

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

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

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

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

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

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

Solution (Python):
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))

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

Solution (Python):
ax1, ay1, bx1, by1 = map(float, input().split())
print(((bx1 - ax1) ** 2 + (by1 - ay1) ** 2) ** 0.5)

Solution (Python):
x1, y1, x2, y2 = map(float, input().split())
z = x1 - x2 + (y1 - y2) * 1j
print(abs(z))

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

x = x1 - x2
y = y1 - y2

print("%.5f" % ((x ** 2 + y ** 2) ** 0.5))

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

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

Solution (Python):
s = input().split()
x1 = float(s[0])
y1 = float(s[1])
x2 = float(s[2])
y2 = float(s[3])

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

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

Solution (Python):




import math

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

Solution (Python):
import sys
import math

x1, y1, x2, y2 = map(float, sys.stdin.read().strip().split())
print('{0:.8f}'.format(math.hypot(x2 - x1, y2 - y1)))

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

Solution (Python):
import math
def main():
    x1, y1, x2, y2 = (float(a) for a in input().split())
    print(math.sqrt((max(x1, x2) - min(x1,x2))**2 + ((max(y1,y2)-min(y1,y2))**2)))

main()

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

Solution (Python):
import math
a=list(map(float,input().split()))

d=math.sqrt(pow(a[0]-a[2],2)+pow(a[1]-a[3],2))

print(d)

Solution (Python):
import math

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

Solution (Python):
import math
def calculateKyori(x1, y1, x2, y2):
    return math.sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)

if __name__ == '__main__':
    x1, y1, x2, y2 = map(float, input().split())
    n = calculateKyori(x1, y1, x2, y2)
    print('{0:.8f}'.format(n))

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

Solution (Python):
import math

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

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

print(d)

Solution (Python):
from math import sqrt

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

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

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

X=(x1-x2)*(x1-x2)
Y=(y1-y2)*(y1-y2)

print("%.10f"%(sqrt(X+Y)))

Solution (Python):
import math
order=list(map(float,input().split()))
print(math.sqrt((order[0]-order[2])**2 + (order[1]-order[3])**2))

Solution (Python):
import math
m=list(map(float,input().split()))
a=m[0]
b=m[1]
c=m[2]
d=m[3]
ans=math.sqrt((c-a)**2+(d-b)**2)
print(round(ans,8))

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

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

Solution (Python):
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))

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

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

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

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
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))

Solution (Python):
import math
a, b, c, d = map(float, input().split())

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

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

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

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

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

Solution (Python):
import math

x1,y1,x2,y2=map(float,input().split())
L=math.sqrt(pow(x1-x2,2)+pow(y1-y2,2))
print(str(L))

Solution (Python):
import math

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

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

Solution (Python):
import math

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

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

Solution (Python):
from enum import Enum
import sys

BIG_NUM = 2000000000
MOD = 1000000007
EPS = 0.000000001

class Point():
    def __init__(self,arg_x,arg_y):
        self.x = arg_x
        self.y = arg_y

def calc_len(a,b):
    from math import sqrt
    return sqrt((a.x-b.x)*(a.x-b.x)+(a.y-b.y)*(a.y-b.y))

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

p1 = Point(x1,y1)
p2 = Point(x2,y2)

print("%.10f"%calc_len(p1,p2))

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

Solution (Python):
import math
coordinate_values = input().split()
values = []
for coordinate_value in coordinate_values:
    values.append(float(coordinate_value))
distance = math.sqrt((values[2] - values[0])**2 + (values[3] - values[1])**2)
print("{:.8f}".format(distance))

Solution (Python):
N=list(map(float,input().split()))

S=((N[0]-N[2])**2+(N[1]-N[3])**2)**0.5
print(S)

Solution (Python):
import math

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

Solution (Python):


import math

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

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

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

Solution (Python):
import math
a,b,c,d = map(float, input().split())
print(format(math.sqrt(pow(c-a,2) + pow(d-b,2)),'.5f'))