Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* С, 7 варіант, 2 лабараторна */
- #include <stdio.h>
- #include <stdlib.h>
- #include <math.h>
- #define Pi 3.14
- /* run this program using the console pauser or add your own getch, system("pause") or input loop */
- int main()
- {
- float V,r,h;
- printf("Enter r,h\n");
- scanf("%f%f", &r,&h);
- V=1/3*(Pi*pow(r,2)*h);
- printf("V=%.2f\n", V);
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement