diff --git a/examples/bare0.rs b/examples/bare0.rs index cb4eb7eadc39a26cc75357e30fa1e5bf688caa72..80ac35a6250966dbf9a1ef72ea621e742281c0e1 100644 --- a/examples/bare0.rs +++ b/examples/bare0.rs @@ -30,16 +30,23 @@ fn main() { // 1. run the program in the debugger, // let the program run for a while and then press pause // look in the (Local -vscode) Variables view what do you find -// ** your answer here ** +// +// (gdb) info locals +// x = 6686607 // // in the Expressions (WATCH -vscode) view add X and Y // what do you find // -// ** your answer here ** +// (gdb) print X +// $19 = 6686606 +// (gdb) print Y +// $20 = 6686606 +// // step through one complete iteration of the loop // and see how the (Local) Variables are updated // can you foresee what will eventually happen? -// ** place your answer here ** +// +// The unsigned 32 bit variable will eventually overflow. // // commit your answers (bare0_1) //