HEAP.py
def HEAP_EXTRACT_MAX(self):
        '''
        caution: whenever call this procedure, make sure that first execute
        the build-heap procedure explicitly
        '''
        if self.isEmpty():
            print('heap is going to be underflow.exit.')
            return
        max = self.A[0]
        self.A[0] = self.A[self.heap_size - 1]
        self.heap_size -= 1
        self.HEAP_MAXIFY(0)
        return max

        caution: whenever call this procedure, make sure that first execute
        the build-heap procedure explicitly
        
whenever call this procedure, make sure that first execute
the build-heap procedure explicitly
whenever call this procedure make sure that first execute the build - heap procedure explicitly
def HEAP_EXTRACT_MAX(self):
        if self.isEmpty():
            print('heap is going to be underflow.exit.')
            return
        max = self.A[0]
        self.A[0] = self.A[self.heap_size - 1]
        self.heap_size -= 1
        self.HEAP_MAXIFY(0)
        return max
def HEAP_EXTRACT_MAX ( self ) : if self . isEmpty ( ) : print ( 'heap is going to be underflow.exit.' ) return max = self . A [ 0 ] self . A [ 0 ] = self . A [ self . heap_size - 1 ] self . heap_size -= 1 self . HEAP_MAXIFY ( 0 ) return max
caution: whenever call this procedure, make sure that first execute
the build-heap procedure explicitly
caution : whenever call this procedure make sure that first execute the build - heap procedure explicitly
'''
        caution: whenever call this procedure, make sure that first execute
        the build-heap procedure explicitly
        '''
self