Okay! Just like there are various types of cells in Excel (numbers, dates, text...), there are also various types of variables in Python. For instance:
current_age = 5
Floating-point numbers (the type is called
float in Python) – numbers with decimal fractions that use dots (
current_weight = 75.5
string) – text values surrounded by single quotes (
' ') or double quotes(
standard_greeting = 'My name is Tom!'
Unlike many other programming languages, Python automatically detects the type of variable it should use. For instance, if you type:
temperature = 36.6
Python will know that the temperature variable is a float because the number contains a dot.