// File: bubble.h
// 
// Header file for bubble sort template

#ifndef _bubble_h
#define _bubble_h

// Template Prototypes

template <class DATA>
void BubbleSort(DATA [], int) ;

// Template Implementations

template <class DATA>
void BubbleSort(DATA A[], int n) {
   int i, j ;
   DATA temp ;

   for (i=0 ; i < n ; i++) {
      for (j = i+1 ; j < n ; j++) {
         if (A[i] < A[j]) {
            temp = A[i] ;
			A[i] = A[j] ;
			A[j] = temp ;
         }
      }
   }

}

#endif
