- Data types
Types of things
Every object in Python, has a type.
We can show what type of thing something is, by calling type
, like this:
type(1)
int
type(1.0)
float
a = 1
type(a)
int
If you get stuck in some code, it is often useful to check what types the objects are.
We will use multiple types when analyzing data. We cover some of the common ones, in this chapter.