Added private helper method analyzeUniqueStrings and code