Using VSCode's debugger you can quickly find bugs!
Objective
We will work with the VSCode debugger to extract a few values from the program and change a variable in the middle of execution.
Review the debugger concepts below, then follow the numbered instructions in main.c to complete the lab.
Debugger Concepts
- Breakpoints pause a running program before a selected line executes. Click beside a source-code line number to add or remove one.
- Continue (F5) resumes execution until the program finishes or reaches another breakpoint.
- Step Over (F10) executes the current line without entering a function call.
- Step Into (F11) enters a function call so you can debug it one line at a time.
- Step Out (Shift+F11) finishes the current function and pauses after returning to its caller.
- The Variables section and editor hover show values that are in scope at the current execution point. Numeric values are normally displayed in decimal.
- While execution is paused, you can double-click an editable value in the Variables section to change it.
Follow the numbered comments in main.c to complete the lab. The flag checker accepts decimal values or hexadecimal values beginning with 0x.