Need to count the occurences of string in an array
userList=["[email protected]","[email protected]","[email protected]"]
Need to get the count of each strings
let userList=["[email protected]","[email protected]","[email protected]"]
Expected : [{"[email protected]":2},{"[email protected]":1}]