Thursday, 18 August 2016
Volume of Cube
Volume of Cube
#include < stdio.h >
void main()
{
float a;
float surface_area,volume;
printf("Enter size of any side of a cube : ");
scanf("%f",&a);
surface_area = 6 * (a * a);
volume = a * a * a;
printf("Surface area of cube is: %.3f",surface_area);
printf("\nVolume of cube is : %.3f",volume);
}
Subscribe to:
Post Comments
(Atom)
0 comments:
Post a Comment