Computer Science, asked by sulman150, 10 months ago

Write a program that inputs a number from the user and displays its square and cube.

Answers

Answered by Arm25
1

Explanation:

#include<iostream>

#include<conio.h>

#include<math.h>

using namespace std;

int main()

{

const float PI=3.14;

float area, circumference, radius;

cout<<"Input radius of spehere: ";

cin>>radius;

area = 4*PI*pow(radius,2);

circumference = (4/3)*PI*pow(radius,3);

cout<<"Area: "<<area<<endl;

cout<<"Circumference: "<<circumference<<endl;

return 0;

}

I hope it is correct

Answered by tyagishanu28
0

Answer: program to solve square and cube of a no.

Explanation:

Def test():

num=int(input ("enter a no."))

Square=num**2

Cube=num**3

print("square of the no. is",

Square)

print("cube of the no. is",

Cube)

I hope it's helpful to you and correct

Thank you

Similar questions