Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- #include <math.h>
- int main (void){
- int x,y,max,min;
- float z,med;
- printf("immetti 3 interi\n");
- scanf("%d%d%f",&x,&y,&z);
- if (x>y)
- max=x;
- else
- max=y;
- if (max<z)
- max=z;
- if (x<y)
- min=x;
- else
- min=y;
- if (z<min)
- min=z;
- med=(x+y+z)/3;
- printf("il max e'%d\n",max);
- printf("il min e'%d\n", min);
- printf("la media e'%f\n", med);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement