Print word count for a text file, sorted by frequency and alphabetically