aboutsummaryrefslogtreecommitdiff
path: root/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
diff options
context:
space:
mode:
authorjacobdw22 <[email protected]>2022-10-22 17:19:55 -0700
committerjacobdw22 <[email protected]>2022-10-22 17:19:55 -0700
commit4597856bd50df6b783d5cc8a21ed17dca9a10265 (patch)
tree9796b4025293dd1fc33cfb83690253babb727b67 /CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
parentsimple changes (diff)
downloadcst116-ch10-debugging-jacobdw22-4597856bd50df6b783d5cc8a21ed17dca9a10265.tar.xz
cst116-ch10-debugging-jacobdw22-4597856bd50df6b783d5cc8a21ed17dca9a10265.zip
Completed Main Debugging Assignments
Diffstat (limited to 'CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp')
-rw-r--r--CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp b/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
index 14549a5..58b37c0 100644
--- a/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
+++ b/CST116-Ch10-Debugging/CST116-Ch10-Debugging.cpp
@@ -80,7 +80,7 @@ using std::setw;
void GetAndDisplayWelcomeInfo();
void FunctionOne(int varX[], int varY[]);
-void FunctionTwo(const int varX[], const int varY[], int varZ[]);
+void FunctionTwo(int varX[], const int varY[], int varZ[]);
void PrintFunction(const int varX[], const int varY[],
const int varZ[]);
@@ -130,10 +130,12 @@ void FunctionOne(int varX[], int varY[])
for (int x = 0; x < SIZE; x++)
varY[x] = x + 100;
}
-void FunctionTwo(const int varX[], const int varY[], int varZ[])
+void FunctionTwo(int varX[], const int varY[], int varZ[])
{
+ varX[1] = { 99 };
for (int x = 0; x < SIZE; x++) // Notice the const SIZE here
varZ[x] = varX[x] + varY[x];
+
}
void PrintFunction(const int varX[20], const int varY[20],
const int varZ[20])