Skip to content

Commit

Permalink
Create code to find distance between points
Browse files Browse the repository at this point in the history
Create code to find distance between points
  • Loading branch information
Thambapanni-Designs authored Oct 17, 2024
1 parent 2f88cf0 commit 2cda2f4
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions distance between points.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import math

x1 = float(input("Enter x1: "))
y1 = float(input("Enter y1: "))
x2 = float(input("Enter x2: "))
y2 = float(input("Enter y2: "))

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


print("The distance between the points is :",distance)

0 comments on commit 2cda2f4

Please sign in to comment.