From 16529d4f1cee37299e90a09c728e3de02cde01b2 Mon Sep 17 00:00:00 2001 From: CEOofOogaBooga Date: Thu, 20 Oct 2022 20:44:44 -0700 Subject: Ch10 finished --- CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp') diff --git a/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp b/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp index e9300c0..13790cb 100644 --- a/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp +++ b/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp @@ -87,7 +87,7 @@ void PrintFunction(const int varX[], const int varY[], const int SIZE = 10;//changed from 5 to 10 int main() -{ +{ int varX[SIZE]; //changed all 5s to SIZE int varY[SIZE]; int varZ[SIZE]; // Notice how we used the const here! @@ -100,6 +100,8 @@ int main() // Breakpoint 3 // Put breakpoint on the following line FunctionTwo(varX, varY, varZ); + varX[1] = 99; //assigning varX so that the 2nd placement/element is 99 + varZ[0] = -99; //assigning varZ so that the 1st placement is -99 PrintFunction(varX, varY, varZ); return 0; -- cgit v1.2.3