My Simple Solution in Python


  • 0
    A

    class Solution(object):
    def findKthLargest(self, nums, k):
    """
    :type nums: List[int]
    :type k: int
    :rtype: int
    """
    nums.sort()
    return nums[-k]


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.