[Python 3]K-Largest Element. 2-liner


#1
import heapq
class Solution:
    # @param A : list of integers
    # @param B : integer
    # @return a list of integers
    def solve(self, A, B):   
        heapq.heapify(A)        
        return heapq.nlargest(B,A)