Array
3396. Minimum Number of Operations to Make Elements in Array Distinct
Given an array nums. Each operation removes the first 3 elements (or all of them if fewer than 3 remain). Find the minimum number of operations so the remaining elements are pairwise distinct.
Loading…