Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

reverse sort cpp


int main(){    
  	int arr[5] = {1,3,2,4,5};
	sort(arr, arr+5, greater<int>()); 
  	// arr == {5,4,3,2,1}
  	return 0;
}
 
PREVIOUS NEXT
Tagged: #reverse #sort #cpp
ADD COMMENT
Topic
Name
8+9 =