You are viewing a single comment's thread. Return to all comments →
the question was pretty hard but can be solved by maintaining a hashmap of the max element and a multiset of the max lengths for that element.
Team Formation
You are viewing a single comment's thread. Return to all comments →
the question was pretty hard but can be solved by maintaining a hashmap of the max element and a multiset of the max lengths for that element.