CProgram

Find the Sphere Surface Area and Volume of a Sphere

Write a C program to find the sphere surface area and volume of a sphere.

/*Program to find Sphere Surface Area and Volume of a Sphere
Sphere Surface Area = 4 * PI * r * r
Volume of Sphere = (4/3) * PI * r * r * r*/
#include <stdio.h>
#define PI 3.142
main()
{
float r, area, vol;
printf(“\nEnter radius of Sphere: “);
scanf(“%f”, &r);
area = 4 * PI * r * r;
vol = (4/3) * PI * r * r * r;
printf(“\nSphere Surface Area = %.2f”, area);
printf(“\nVolume of Sphere = %.2f”, vol);
getch();
}

Excited
0
Happy
0
In Love
0
Not Sure
0
Silly
0

C

C

C

Reverse the order of each word of the string using pointers

Write a C program to reverse the order of each word of the string using ...

Convert temperature from degree centigrade to Fahrenheit

Write a C program to convert temperature from degrees Centigrade to Fahrenheit. #include<stdio.h> int main() { float celsius, fahrenheit; ...

Program to find Average of three Real Numbers

Write a C program to an average of three real numbers. #include <stdio.h> main() { ...

Find Area of Square & Circumference of a Circle

Write a C program to find the area of a square & circumference of a ...