Home / Python Fundamentals / Variables & Types
Lesson 1 of 8

Variables & Types

Concept

A variable is a name that points to a value. Python figures out the type automatically — you don't declare it. The main types you'll see in your code: str (text), int (whole numbers), bool (True/False), float (decimals).
m3shdup/app/intrinsic.py
COOLDOWN_AGENT = "_intrinsic_global"   # str
IDLE_MINUTES = 10                       # int
DRY_RUN = False                         # bool
UCB_CAP = 2.0                           # float

What's happening

These are from your mesh codebase. Python knows "_intrinsic_global" is a string because of the quotes, 10 is an int because it's a whole number, and 2.0 is a float because of the decimal point.

Quick Check — 3 questions

1. What type is "hello"?

2. What type is True?

3. What does NODE_PORT = 64295 create?