How will you sort the elements of array in descending order?
Answer / Manoj Agarwal
To sort an array in descending order, you can use the Arrays.sort() method in Java with a custom Comparator that reverses the natural ordering of elements.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is bubble sort used for?
What is the difference between array and list?
What is complete binary tree in data structure?
Does treemap sort on key or value?
Do you know how to find if linked list has loop?
What is sorting in data structure?
How do you create a tree diagram?
Why might quick sort might be better than merge sort?
What is array sort?
What is a priority queue?
What are the advantages and disadvantages of linked list?
What do you mean by union-by-weight?