---
title: "Chapter 3: Debugging Rust Programs"
description: "The 7 lessons of chapter 3: Debugging Rust Programs, in teaching order."
url: "https://learnrust.net/chapter-3/"
last_updated: "2026-06-11"
---

# Chapter 3: Debugging Rust Programs

- [3.1 Syntax and semantic errors](https://learnrust.net/chapter-3/syntax-and-semantic-errors.md): The two kinds of programming errors, which ones Rust's compiler catches, and which ones survive to runtime.
- [3.2 The debugging process](https://learnrust.net/chapter-3/the-debugging-process.md): A six-step process for finding and fixing bugs, applied to a real broken program.
- [3.3 A strategy for debugging](https://learnrust.net/chapter-3/a-strategy-for-debugging.md): Narrowing down where a bug lives: code inspection, reproduction, and binary-searching the pipeline.
- [3.4 Print debugging: eprintln! and dbg!](https://learnrust.net/chapter-3/print-debugging.md): Debugging with output: stderr versus stdout, the dbg! macro's file-and-line reports, and a worked bug hunt.
- [3.5 Using a debugger: breakpoints and stepping](https://learnrust.net/chapter-3/using-a-debugger.md): Pausing a live Rust program with a debugger: breakpoints, stepping, watching variables, and the call stack, in VS Code and elsewhere.
- [3.6 Finding issues before they become problems](https://learnrust.net/chapter-3/finding-issues-early.md): Habits that prevent bugs: small functions, incremental builds, defensive thinking, Clippy, and a taste of automated tests.
- [3.x Chapter 3 summary and quiz](https://learnrust.net/chapter-3/chapter-3-summary-and-quiz.md): Debugging terms in review, plus a quiz of real broken programs to hunt through.

## Sitemap

See the full [sitemap](https://learnrust.net/sitemap.md) for all pages.
