aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp7
-rw-r--r--cst116-ch10-debugging-wilson-pseudo-code.txt0
-rw-r--r--cst116-ch10-debugging-wilson.txt0
3 files changed, 4 insertions, 3 deletions
diff --git a/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp b/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
index 1e3d58b..14549a5 100644
--- a/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
+++ b/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
@@ -84,11 +84,11 @@ void FunctionTwo(const int varX[], const int varY[], int varZ[]);
void PrintFunction(const int varX[], const int varY[],
const int varZ[]);
-const int SIZE = 5;
+const int SIZE = 10;
int main()
{
- int varX[5];
+ int varX[SIZE];
int varY[SIZE];
int varZ[SIZE]; // Notice how we used the const here!
@@ -100,6 +100,7 @@ int main()
// Breakpoint 3
// Put breakpoint on the following line
FunctionTwo(varX, varY, varZ);
+ varZ[0] = { -99 };
PrintFunction(varX, varY, varZ);
return 0;
@@ -126,7 +127,7 @@ void FunctionOne(int varX[], int varY[])
// Put breakpoint on the following line
varX[x] = x;
- for (int x = 0; x < 5; x++)
+ for (int x = 0; x < SIZE; x++)
varY[x] = x + 100;
}
void FunctionTwo(const int varX[], const int varY[], int varZ[])
diff --git a/cst116-ch10-debugging-wilson-pseudo-code.txt b/cst116-ch10-debugging-wilson-pseudo-code.txt
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/cst116-ch10-debugging-wilson-pseudo-code.txt
diff --git a/cst116-ch10-debugging-wilson.txt b/cst116-ch10-debugging-wilson.txt
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/cst116-ch10-debugging-wilson.txt