Guest User

Untitled

a guest
Jan 24th, 2018
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.38 KB | None | 0 0
  1. #include<stdio.h>
  2. #include<math.h>
  3. main()
  4. {
  5.     float x1,x2,y1,y2,x,y,d;
  6.     printf("Upisite kordinate prve tocke: ");
  7.     scanf("%f,%f",&x1,&y1);
  8.     printf("\nUpisite kordinate druge tocke: ");
  9.     scanf("%f,%f",&x2,&y2);
  10.     x = x2-x1;
  11.     y = y2-y1;
  12.     d = sqrt(pow(x,2)+pow(y,2));
  13.     printf("\nTocke su medusobno udaljene %f",d);
  14.     scanf("%d");
  15.     return 0;
  16. }
Add Comment
Please, Sign In to add comment