Answers for "can we sort the array descending using sort function c++"

C++
12

how to sort in descending order c++

int arr[10];
int length = sizeof(arr)/sizeof(arr[0]); 
sort(arr, arr+length, greater<int>());
Posted by: Guest on May-16-2020

Code answers related to "can we sort the array descending using sort function c++"

Browse Popular Code Answers by Language