Simple Python Solution using list
InterviewBit Problems
K Largest Elements : Solved
nilesh-mathur-17blc1
2020-07-16 11:43:17 UTC
#1
def solve(self,A,B):
l1=[]
A.sort(reverse=True)
for i in range(B):
l1.append(A[i])
return l1