Challenge: Find K Largest Elements in an Array
Try to solve the Find K Largest Elements in an Array problem.
We'll cover the following...
Statement
Given an array of integers, nums
, and a positive integer, k
, find the k largest elements in the array.
Constraints:
k
nums.length
nums[i]
Example
Let’s take a look at a few examples to get a better understanding of the problem statement:
Access this course and 1400+ top-rated courses and projects.