Write a C++ program to sort digits of all the 4 digit number
and display the sorted 4 digit number
Answer Posted / prasadnvk
i=0
while(num>0)
{
digit=num%10;
digitarr[i++]=digit;
num=num/10;
}
then sort the digitarr
Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
What is the difference between strcpy() and strncpy()?
What is guard code in c++?
What is set in c++?
How do I run c++?
Is c++ double?
What are the unique features of C++.
What are the benefits of c++?
what is a class? Explain with an example.
Can a constructor be private?
Define token in c++.
What are the differences between malloc() and calloc()?
How can you quickly find the number of elements stored in a a) static array b) dynamic array ? Why is it difficult to store linked list in an array?how can you find the nodes with repetetive data in a linked list?
What do you mean by storage classes?
Is c++ harder than java?
Why is it necessary to use a reference in the argument to the copy constructor?