Data Types

Data Types

Data types define what information is stored

The most used of them are:

Type Description Example
numeric Whole or floating number. num = 5

num = 7.2
string Sequence of symbols (text). text = 'Python is awesome!'
boolean Can have only 2 values - True or False. isAwesome = True

Printing Data

It's done using print.

Variables

The variables are used to store data of certain type.

Their value can be changed any time.

Example of variables definitions:

Basic program example:

Write a program in which variables are defined and printed.

Solution:

Output: