Daffodil International University
Problem Link
//Please follow from main function
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main()
{
double x, x1, x2, y, y1, y2, Distance;
scanf("%lf %lf %lf %lf", &x1, &y1, &x2, &y2);
x=(x2-x1)*(x2-x1);
y=(y2-y1)*(y2-y1);
Distance=sqrt(x+y);
printf("%.4lf\n", Distance);
return 0;
}
0 Comments