How to check data type in Python

How to check data type in Python

In this article, you’ll see how to check data type in Python. To find the data type of a variable in Python use the built-in function type(variable). I highly recommend you get the “Python Crash Course Book” to learn Python. Output: <class ‘int’> <class ‘float’> <class ‘str’> <class ‘complex’> <class ‘list’> <class ‘tuple’> <class ‘dict’> <class ‘set’>