Added the getWordsCount function in String module