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 is a Default constructor?

917


Is c++ used anymore?

586


What are the differences between malloc() and calloc()?

612


What is object in c++ wikipedia?

568


Define private, protected and public access control.

604






What is abstraction in c++ with example?

560


What do you mean by stack unwinding in c++?

728


What is a volatile variable in c++?

556


What do you mean by static variables?

602


What doescout<<(0==0) print out a) 0 b) 1 c) Compiler error: Lvalue required

573


Why c++ is the best language?

592


What is the use of string in c++?

549


What is the basic difference between C and C++?

622


What is c++ runtime?

651


What are the rules for naming an identifier?

560