Lesson 1 · Data analytics zero to hero
Python Variables & Data Types Explained | Data Analytics #1
Welcome to the first video in a full 30-part series taking you from zero to a job-ready data analyst, entirely in Python. This video covers the absolute…
- CourseData analytics zero to hero
- Lesson1 of 30
- Video13 min
- FormatJupyter notebook · 12 code cells
What you'll learn
Data
No separate download needed — the notebook creates or downloads everything it uses.
📓 Full notebook
Download .ipynbData Analytics Zero to Hero, Video 1: Variables, Data Types, and Operators#
- Welcome to the first video in a full 30-part series taking you from zero to a job-ready data analyst, entirely in Python.
- This video covers the absolute foundation: variables, the core data types, and the operators you'll use in every single video that follows.
- No prior programming experience needed. Let's jump straight in.
Before You Start#
- Install Python 3 from python.org (on Windows, check 'Add python.exe to PATH'), then install VS Code from code.visualstudio.com with its Python and Jupyter extensions.
- Open the Command Palette (Control/Command plus Shift plus P), run 'Create: New Jupyter Notebook', and select your Python interpreter as the kernel.
Part 1: Variables#
age = 28
print(age)
age = 29
print(age)
Naming Rules#
first_name = 'Ada'
last_name = 'Lovelace'
print(first_name, last_name)
Part 2: Core Data Types#
whole_number = 42
decimal_number = 3.14
text = 'Data Analytics'
is_active = True
print(type(whole_number))
print(type(decimal_number))
print(type(text))
print(type(is_active))
Converting Between Types#
price_text = '19.99'
price_number = float(price_text)
print(price_number)
print(price_number * 2)
print(str(price_number) + ' dollars')
age_text = str(29)
print(age_text, type(age_text))
Part 3: Arithmetic Operators#
a = 17
b = 5
print(a + b)
print(a - b)
print(a * b)
print(a / b)
print(a // b)
print(a % b)
print(a ** 2)
Part 4: Comparison and Logical Operators#
x = 10
y = 20
print(x == y)
print(x != y)
print(x < y)
print(x >= 10)
has_ticket = True
has_id = False
print(has_ticket and has_id)
print(has_ticket or has_id)
print(not has_id)
Part 5: Formatting Output with f-strings#
name = 'Priya'
score = 87.456
print(f'{name} scored {score} points')
print(f'{name} scored {score:.1f} points')
revenue = 48213.7
print(f'Total revenue: ${revenue:,.2f}')
Wrap-Up: What You Learned#
- Variables: creating them, reassigning them, and Python's snake_case naming convention.
- The four core data types: int, float, str, and bool, plus converting between them.
- Arithmetic operators, including floor division and modulo.
- Comparison operators, which always return a bool, and the and/or/not logical operators.
- f-strings for embedding variables in text, with precise number formatting.
- Everything here is the vocabulary the rest of this 30-video series is written in. Subscribe so video two, on control flow, lands in your feed next see you there.
Found this useful?
All lessons, notebooks and datasets here are free. If they helped you, a coffee keeps new lessons coming.



