Search This Blog

Translate

C program to calculate square and cube of a given number

 C program to calculate square and cube of a given number

void main()
{
    int no;
    clrscr();
    printf("Enter the number=");
    scanf("%d",&no);
    printf("\n\n******* Result *********");
    printf("\n\nSquare of %d is %d.",no,no*no);
    printf("\n\nCube of %d is %d.",no,no*no*no);
    getch();
}


 C program to calculate square and cube of a given number

C Program example List

Google+ Badge