tools/debugging-for-beginners-step-through-code-to-find-an-off-by-one.md
Debugging for beginners: step through code to find an off-by-one
Your code prints 6 and you expected 10. A debugger lets you slow the program down, run one line at a time, and watch every variable change, so you can see exactly where reality stops matching your expectation.
Step through a tiny Python function in the page, spot the off-by-one hiding in range(1, n), then learn how to do the same on your own computer with breakpoint() and your editor.
$ ls tools/
see all →
tools/your-first-terminal-commands-pwd-ls-cd-and-friends-with-no-fear.md
Your first terminal commands: pwd, ls, cd and friends, with no fear
The terminal is a window where you type commands instead of clicking, and about a dozen of them cover most of what you'll do every day…
tools/git-basics-where-your-work-lives-and-why-branches-are-just-pointers.md
Git Basics: Where Your Work Lives and Why Branches Are Just Pointers
Git saves your project's history as commits: snapshots you choose to take, each with a short message. The trick to understanding it is…