Updated wordcount to presort so that uniq will accept the neighboring lines.