+ 1

What's wrong with unordered_map with custom hash function

I tried to have an unordered_map of custom class object as key. I am trying to use hash function from a new custom class, but not sure what is issue. Refer code below: https://code.sololearn.com/cupRKITB1gFb TrialUnorderedMap need some modification. I don't want to use custom equality as new class but new hasher I need as defined. Any thought?

2nd Apr 2022, 10:04 AM
Ketan Lalcheta
Ketan Lalcheta - avatar
2 odpowiedzi
+ 3
You are using a map instead of an unordered_map at the moment.
2nd Apr 2022, 10:27 AM
Shadow
Shadow - avatar
+ 1
Thanks... my bad
2nd Apr 2022, 11:51 AM
Ketan Lalcheta
Ketan Lalcheta - avatar