<s> import heapq <EOL> class Heap ( list ) : <EOL> def __init__ ( self , * args , ** kwargs ) : <EOL> list . __init__ ( self , * args , ** kwargs ) <EOL> heapq . heapify ( self ) <EOL> def pop ( self ) : <EOL> return heapq . heappop ( self ) <EOL> def push ( self , item ) : <EOL> heapq . heappush ( self , item ) <EOL> def peek ( self ) : <EOL> return self [ <NUM_LIT:0> ] <EOL> def pushpop ( self , item ) : <EOL> return heapq . heappushpop ( self , item ) <EOL> def poppush ( self , itemp ) : <EOL> return heapq . replace ( self , item ) </s>
