How to get unique values with respective occurrence count from a list in Python

Published --