Practical Python
Real programs read data, clean text and talk to web services. Each lesson uses examples you can run against browser-friendly public APIs.
- 1Working with JSON in PythonJSON is a plain-text format for structured data, and Python's built-in json module converts JSON text into di…Practical example✓
- 2Python CSV FilesA CSV file stores a table as plain text — one row per line, values separated by commas — and Python's csv mod…Practical example✓
- 3Python Regular Expressions (regex)A regular expression (regex) is a short pattern that describes the shape of some text — such as "three digits…✓
- 4Python requests: Call Web APIsThe requests library lets your Python code send HTTP requests to web servers and APIs and read their response…✓
- 5Python API Example: Build an API ClientAn API client is a small program that sends HTTP requests to a web service, checks the reply, turns the JSON …Practical example✓
- 6Python SQLiteSQLite is a small database built into Python's `sqlite3` module that stores data in tables you create, fill a…Practical example✓
- 7Python LoggingThe logging module records messages from your program with a severity level, a source name and a destination …Practical example✓
- 8Python TestingA test is code that calls your code with known inputs and automatically checks that the results are what you …Practical example✓
- 9Python pip and Virtual Environmentspip installs third-party packages from PyPI, and a virtual environment gives each project its own private set…Practical example✓
Start with Working with JSON in Python →
About Practical Python
Practical skills connect Python to the real world: JSON and CSV files, regular expressions, web APIs with requests, SQLite databases, logging, testing, and packages with virtual environments. These are the tools that turn exercises into useful scripts.
Related reference: Regex cheat sheet · Install a package with pip · Create a virtual environment
Further reading (official documentation)
Practice for this topic
Working with JSON in Python exercises
4 exercises · checked in your browser
Python CSV Files exercises4 exercises · checked in your browser
Python Regular Expressions (regex) exercises4 exercises · checked in your browser
Python requests: Call Web APIs exercises4 exercises · checked in your browser
Python API Example: Build an API Client exercises4 exercises · checked in your browser
Python SQLite exercises4 exercises · checked in your browser
Python Logging exercises4 exercises · checked in your browser
Python Testing exercises4 exercises · checked in your browser
Python pip and Virtual Environments exercises4 exercises · checked in your browser