diff options
| -rw-r--r-- | CST116-Ch7-Debugging/CST116-Ch7-Debugging.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/CST116-Ch7-Debugging/CST116-Ch7-Debugging.cpp b/CST116-Ch7-Debugging/CST116-Ch7-Debugging.cpp index d795af0..a4c6726 100644 --- a/CST116-Ch7-Debugging/CST116-Ch7-Debugging.cpp +++ b/CST116-Ch7-Debugging/CST116-Ch7-Debugging.cpp @@ -44,6 +44,9 @@ * 2) When prompted, enter the value of 10 for your age.
* Done
* 3) Why does the program print both "Child" and "Adult"?
+*
+* Because the code always prints adult after the "if" statements.
+*
* 4) Re-run the program this time with debugging and run to
* Breakpoint 2.
* 5) Why is the action with the else executing?
|