we have that
Leg 1 ------> vertical side
Leg 2 -----> horizontal side
so
Find out the length side Leg 1
Subtract the y-coordinates of the given points (absolute value)
Leg 1=-3-(-7)=-3+7=4 units
Find out the length side Leg 2
Subtract the x-coordinates of the given points (absolute value)
Leg 2=2-(-3)=2+3=5 units
Find out the distance of the hypotenuse
Applying the formula to calculate the distance between two points