the number 138 is called well ordered number because the
three digits in the number (1,3,8) increase from left to right
(1<3<8). the number 365 is not well ordered coz 6 is larger
than 5.
write a program that wull find and display all possible
three digit well ordered numbers.
sample:
123,124,125,126,127,128,129,134
,135,136,137,138,139,145,146,147
148
149,156.......789
Answer Posted / santosh kumar
for(int i=0;i<8;i++)
for(int j=i+1;j<9;j++)
for(int k=j+1;k<10;k++)
printf("%d\t", i*100+j*10+k);
Is This Answer Correct ? | 7 Yes | 15 No |
Post New Answer View All Answers
What is the translation phases used in c language?
What is a method in c?
Explain what’s a signal? Explain what do I use signals for?
How can you determine the size of an allocated portion of memory?
What is the difference between declaring a variable and defining a variable?
Difference between goto, long jmp() and setjmp()?
When should you not use a type cast?
Tell us something about keyword 'auto'.
What are valid operations on pointers?
Write a program to check prime number in c programming?
What is the use of extern in c?
What does calloc stand for?
What is the function of multilevel pointer in c?
What are pointers? What are different types of pointers?
Write a program to print fibonacci series without using recursion?