HelloC/pythagoras.c
2023-11-25 19:27:12 +01:00

17 lines
219 B
C

#include <stdio.h>
#include <math.h>
int main() {
int a, b;
double c;
printf("a? ");
scanf("%d", &a);
printf("b? ");
scanf("%d", &b);
c = sqrt((a*a) + (b*b));
printf("c: %f\n", c);
}