medium10 pts · first answer countshash-mapcountingperformance
Array or map for counting small integers
You count exam scores from 0 to 100 for 50 lakh students. Why is an array of 101 counters better than a hash map?
Discussion 0
Join free to post in the discussion.
Related questions
- Slow email during signupBackend Developer
- What EXPLAIN tells youBackend Developer
- Asking for only a few fieldsBackend Developer
- Building a long string in a loopBackend Developer
- Checking if any rows existBackend Developer
- Paths across a 3 × 7 gridBackend Developer
- Average cost of a hash map lookupBackend Developer
- Worst case for a hash map lookupBackend Developer