C-Program To Find the Product Of CUBES of Natural Numbers UP to a Limit
#include<stdio.h>
main ()
{
int prdct=1,n,i;
printf("Enter the Limit\t");
scanf("%d",&n);
for(i=1;i<=n;i++)
{
prdct=prdct*i*i*i;
}
printf("Product of Cubes Upto %d is %d",n,prdct);
}
 |
| output |
No comments:
Post a Comment