added counting of unique words using Counter