code: def max_pairs(shape):
      
  
      if not isinstance(shape, (tuple, list)):
          x = get_length(shape)
          n = int(x * (x - 1) / 2)
  
      elif (isinstance(shape, (tuple, list)) and len(shape) == 1):
          x = get_length(shape[0])
          n = int(x * (x - 1) / 2)
  
      else:
          n = numpy.prod([get_length(xi) for xi in shape])
  
      return n
docs: [DEPRECATED] Compute the maximum number of record pairs possible.