how to check the variable type in python code example
Example 1: print variable type python
v = 10
type(v)
# <type 'int'>
Example 2: how to check the type of a variable in python
print(type(x))
Example 3: how to check if a variable in python is a specific data type
isinstance(variable_name, class_name) #eg. isinstance(age, int) will return True