2 Incorporated J.M.'s comment into the answer edited Mar 4 at 7:19 m_goldberg 91.6k88 gold badges7575 silver badges209209 bronze badges You can try Tally lst = {"aa bb", "cc dd", "aa bb", "aa bb", "cc dd", "ww ss", "ss ss", "kk mm"}; Tally[lst]  Edit by m_goldberg As J.M. says in his comment below, Counts will give the same information as an association. Counts[data]  <|"aa bb" -> 3, "cc dd" -> 2, "ww ss" -> 1, "ss ss" -> 1, "kk mm" -> 1|> This is equivalent to Rule @@@ Tally[data] // Association  You can try Tally lst = {"aa bb", "cc dd", "aa bb", "aa bb", "cc dd", "ww ss", "ss ss", "kk mm"}; Tally[lst]  You can try Tally lst = {"aa bb", "cc dd", "aa bb", "aa bb", "cc dd", "ww ss", "ss ss", "kk mm"}; Tally[lst]  Edit by m_goldberg As J.M. says in his comment below, Counts will give the same information as an association. Counts[data]  <|"aa bb" -> 3, "cc dd" -> 2, "ww ss" -> 1, "ss ss" -> 1, "kk mm" -> 1|> This is equivalent to Rule @@@ Tally[data] // Association  1 answered Mar 4 at 4:36 Nasser 62.2k44 gold badges9393 silver badges217217 bronze badges You can try Tally lst = {"aa bb", "cc dd", "aa bb", "aa bb", "cc dd", "ww ss", "ss ss", "kk mm"}; Tally[lst]