Create a C++ function that orders an array
Input: No input
void orderArray(int arr[]) {
    // Loop through the array
    for (int i = 0; i < arr.length; i++) {
        // Find where the element should go
        int j = arr.length - 1;

        // Move the element to the required position
        while (arr[j] > arr[i]) {
            arr[j] = arr[i];
            j = i;
        }
        arr[j] = arr[i];
    }
}
void swap(int arr[]) {
   int i, j;
   for (i=0; i<n; i++) {
    j = arr[i];
    arr[i] = arr[n-j];
    arr[n-j] = j;
   }
 }