Function to return the sum of the minimum pair from the array
static int smallest_pair ( int [ ] a , int n ) { int min = Integer . MAX_VALUE , secondMin = Integer . MAX_VALUE ; for ( int j = 0 ; j < n ; j ++ ) {