Learn practical skills, build real-world projects, and advance your career

Built-in data types in Python

Any data or information stored within a Python variable has a type. The type of data stored within a variable can be checked using the type function.

ython has several built-in data types for storing different types of information in variables. Following are at some commonly used data types:

  1. Integer
  2. Float
  3. Boolean
  4. None
  5. String
  6. List
  7. Tuple
  8. Dictionary

Integer, float, boolean, None and string are primitive data types because they represent a single value. Other data types like list, tuple and dictionary are often called data structures or containers because they hold multiple pieces of data together.

5 + False
3. + True

False = 0

True = 1