/*Using power function find the cube of any number */
#include "stdio.h"
#include "math.h"
int main ()
{
int num,cube ;
printf ("Enter the number :\n");
scanf ("%i",&num);
cube=pow(num,3);
printf ("cube of %i is %i",num,cube);
return 0;
}
output output output output
Enter the number :
5
cube of 5 is 125
No comments:
Post a Comment