Frequency Queries

  • + 0 comments

    Great suggestion. You are right. No need of changing the boiler plate code. But instead of setting the initial capacity using hash map, I used a linked hash map and that worked. Linked Hash Map doesn't have the added time complexity of resizing (i.e. everytime the length exceeds the default size)