Search
⌘K

Leetcode 697. Degree of an Array

Find the smallest length contiguous subarray whose degree (maximum element frequency) equals the degree of the whole array — essentially identify the elements that achieve the global max frequency and return the minimal span that covers all occurrences of any such element.


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Comments

Your account is free and you can post anonymously if you choose.