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 / leosoft

#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 ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are destructors?

584


What is meaning of in c++?

683


What is a class definition?

624


What is called array?

624


Explain data encapsulation?

622






What is class in c++ with example?

582


What is basic if statement syntax?

581


What do you mean by overhead in c++?

590


What information can an exception contain?

675


What is conditions when using boolean operators?

610


What is an iterator?

696


Is sorted c++?

586


How many types of scopes are there in c++?

589


Differentiate between a constructor and a method in C++.

568


How should runtime errors be handled in c++?

619