Several reasons, including the fact that uniq will only remove adjacent identical lines. If we didn't sort the words, instances of the, for example, wouldn't be adjacent to each other. Further, if we didn't break up the file into one word per line, no lines would be identical.