Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Performance comparison: counting words in Python, C/C++, Awk, Rust, and more. Parent comment
Neither simple.c nor optimized.c call malloc "for every word". They only call malloc when inserting a previously-unseen word into the counting map.
There are no comments on this comment yet.
Neither simple.c nor optimized.c call malloc "for every word". They only call malloc when inserting a previously-unseen word into the counting map.