Skip to content

Commit

Permalink
[LeetCode] Add January 16.
Browse files Browse the repository at this point in the history
  • Loading branch information
pin3da authored Jan 16, 2021
1 parent 8b1b548 commit b87c1d3
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions solved/LeetCode/Challenges/2020/January/16.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
class Solution {
fun findKthLargest(nums: IntArray, k: Int): Int {
val sorted = nums.sorted().reversed()
return sorted[k-1]
}
}

0 comments on commit b87c1d3

Please sign in to comment.