← Expedia questions

Minimum number of distinct elements after removing m items

Filed under Expedia · Also reported at Infoedge, PayPal

Given an array of integers and an integer m, you need to remove exactly m elements from the array such that the number of distinct elements remaining in the array is minimized. Return the count of the…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Expedia questions

Collected from public candidate posts and coding forums. Updated Nov 2026.