1.Between 100 and 999 are some numbers that have the
characteristics that if you cube the individual digits and
sum together you will get the same number.

2. A program that can accept as input an integer and output
the equivalent of that number in words.

Answer Posted / thirunavukkarasu

#include<stdio.h>
#include<math.h>
int a,b,c;
int main()
{

for(a=0;a<=9;a++)
{
for(b=0;b<=9;b++)

{
for(c=0;c<=9;c++)

if ((a*a*a)+(b*b*b)+(c*c*c)==(100*a)+(10*b)+(c))

printf("\nThe Numbers are :%d",(100*a)+(10*b)+(c));
}
}
return 0;
}

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can I improve my c++ skills?

556


Is c++ a good first language to learn?

573


Can we make any program in c++ without using any header file and what is the shortest program in c++.

614


How does a copy constructor differs from an overloaded assignment operator?

554


When do you call copy constructors?

647






What is meant by a delegate?

606


Explain explicit container.

633


What is the difference between an external iterator and an internal iterator? Describe an advantage of the external iterator.

560


How a macro differs from a template?

635


Discussion on error handling of C++ .

644


What is the best ide for c++?

569


How can you quickly find the number of elements stored in a dynamic array? Why is it difficult to store linked list in an array?

558


What is enum c++?

614


Explain linked list using c++ with an example?

631


Explain the virtual inheritance in c++.

594