The length of the hypotenuse is the distance between the two points. The shortest path distance is a straight line. It is necessary to follow the next steps.
For example the shortest distance between any two points is always a straight line between them check the linear interpolation calculator.
Calculate Y 2 -Y 1 2. Where x 1 y 1 and x 2 y 2 are the coordinates of the two points involved. X 2 x 1 2 y 2 y 1 2. The distance between two points calculation formula is similar to the right triangle rule where the squared hypotenuse is equal to the sum of the squares of the other two sides.