Ways to find out the count of unique items in a list using python

Last day I was trying for a method to find the count of unique items in a list. I found two solutions. Thought like it is worth to share here.

Method 1:

This method works only with python versions 2.7 and above. The collections library is not available in python versions less than 2.7.

Method 2:

This is a very simple method using python dictionary. This will work in all versions of python.