All challenges
Code AnalysisHard 60s

Custom hash specialization misuse

struct Key { int a, b; }; namespace std { template<> struct hash<Key> { size_t operator()(const Key& k) const { return k.a + k.b; } }; } What is the main correctness concern?

Think you can answer under pressure?

Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.

Play this in a 3-minute battle