We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
I failed with c++ because of map.count(element). when the element count is 0, it still registers as a hit. Somewhat confusing if you choose to use this language reference. its better to check with if(map.count(element) && map.count(element) != 0). good problem.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Anagram
You are viewing a single comment's thread. Return to all comments →
I failed with c++ because of map.count(element). when the element count is 0, it still registers as a hit. Somewhat confusing if you choose to use this language reference. its better to check with if(map.count(element) && map.count(element) != 0). good problem.