```
class Solution(object):
def findKthLargest(self, nums, k):
"""
:type nums: List[int]
:type k: int
:rtype: int
"""
if k>len(nums) or k<=0:
return None
rst=nums[:k]
rst.sort()
for i in range(k, len(nums)):
if nums[i]>rst[0]:
rst.append(nums[i])
rst.pop(0)
rst.sort()
return rst[0]
```