Hi,

i'm new to Julia and wrote a baseline implementation of word count, that
counts words, and writes them to stdout sorted by counts (highest first),
and when tie, using alphabetical order.
My code is here:
https://github.com/juditacs/wordcount/blob/master/julia/wordcount.jl

Half of the time is spent if secondary sorting is used (for alphabetical
order), this is the first bottleneck. But string addition to the dict is
quite slow.
The python/cpp implementation runs for about 20-25 seconds while this
implementation runs for 80 seconds.
Can you give me some hints on why this implementation is slow?

Thank you!

Attila

Reply via email to