There are many more types in Python (you can even define your own custom types) but for the time being these built-in types will take us a long way.
There is one special value that we shall introduce here as well: None
is a value used to express nothing or absence (often relating to some value that is optional) and its type is NoneType
. We will provide a more concrete example when we talk about functions, but for now this example demonstrates what we mean:
x = None print(type(x))
For now, think of None
as the value to assign to a variable if the variable may or may not be used in a program.