type() function returns the type of the data it receives as an argument. If you ask Python to do the following:
print type(42) print type(4.2) print type('spam')
Python will output:
<type 'int'> <type 'float'> <type 'str'>
Have Python print out the type of an
float, and a
str string in the editor. You can pick any values on which to call
type(), so long as they produce one of each.