isinstance(yourNumber, float) # returns True if it's a float. Notice that Python 2 has both types int and long, while Python 3 has only type int. Source. If you want to check whether your number is a float that represents an int, do this. (isinstance(yourNumber, float) and (yourNumber).is_integer()) # True for 3.0. More @Wikipedia
Hover over any link to get a description of the article. Please note that search keywords are sometimes hidden within the full article and don't appear in the description or title.