MarketAxess interview question

Degree of an Array (Leetcode)

Interview Answer

Anonymous

Sep 2, 2021

Used HashMaps to track start index, last index, frequency and a map of frequency to a list of items with that frequency. Used maps to figure out highest frequency and shortest path