#include<stdio.h>

// Bubble Sort #2 - Descending Order
void bubbleSortDesc(int numbers[], int Max)
{
  int i, j, temp;

  for (i = (Max - 1); i >= 0; i--)
  {
    for (j = 1; j <= i; j++)
    {
      if (numbers[j-1] < numbers[j])
      {
        // Exchange the adjacent elements
        temp = numbers[j-1];
        numbers[j-1] = numbers[j];
        numbers[j] = temp;
      }
    }
  }

  // To display the sorted list onto the screen
  printf("\n\nSorted list is \n\n");
  for (i=0; i<Max; i++)
     printf("%d\n",numbers[i]);
}
 
// Bubble Sort Implementation - Sort by Descending Order
int main()
{
   int a[]={200,5,254,23,76,34,215,65,5634,132,6757,2423,664,2345};
   int array_size=14;
   bubbleSortDesc(a,array_size);
   return 0;
} // End of main