hard20 pts · first answer countshash-mapjavascriptdebugging
Word counts that break on "constructor"
This word counter gives a strange string for the word "constructor". Why?
const counts = {}
for (const w of words) counts[w] = (counts[w] || 0) + 1Discussion 0
Join free to post in the discussion.
Related questions
- What a 504 from Nginx meansBackend Developer
- Python default list surpriseBackend Developer
- fetch treats a 404 as successBackend Developer
- slice vs spliceBackend Developer
- indexOf and NaNBackend Developer
- new Array(3) then mapBackend Developer
- Value missing from indexOfBackend Developer
- parseInt on a CSS valueBackend Developer