Exercises/#62 Kth Largest Element
#62

Kth Largest Element

MediumπŸ” Sorting & Searching
80 XP

Problem

Given an integer array nums and integer k, return the kth largest element.

Examples

Input: nums=[3,2,1,5,6,4], k=2
Output: 5

Input: nums=[3,2,3,1,2,4,5,5,6], k=4
Output: 4
heapsortingquickselect
AI Assistantβ€” powered by AI

Unlock hints progressively β€” start gentle, go deeper only if needed.

πŸ’‘

Level 1: Gentle Nudge

A subtle direction

πŸ—ΊοΈ

Level 2: Approach

The algorithm to use

πŸ”

Level 3: Detailed

Step-by-step guidance

62 / 150

Your Solution

⚑ JavaScript

to save progress and use AI features