Classes C++ program to display the cube of the number up to a given integer

Write a program in C++ to display the cube of the number up to a given integer using class objects in object-oriented programming.

Output

enter the number : 3

cube of 0 is 0.

cube of 1 is 1.

cube of 2 is 8

 

Add a Comment