Program to find square and cube of a number (C++)

Program to find square and cube of a number in C++

-Program:

#include <stdio.h>
void main()
{

int n;
clrscr();
printf(“Enter number:”);
scanf(“%d”, &n);
printf(“Square is %d and cube is %d”, n*n, n*n*n);
getch();
}

-Output:

cprogram

Program to find square and cube of a number


“My posts/articles/images are not allowed to be stolen/copied anywhere at Cyber space. Doing so will allow me to take a legal action against the copier.”

Related Posts

M.Bakhtiar Zuberi
Hello, I'm M.Bakhtiar Zuberi, the only article poster & owner of this website. Your comments/suggestions are welcomed the most! RajasTutorials.com is a part of 3DPixelz.com network.

Leave a Comment

Kindly solve the following puzzle to prove that you\'re not a bot: