diff options
| author | Connor McDowell <[email protected]> | 2024-02-15 17:35:32 -0800 |
|---|---|---|
| committer | Connor McDowell <[email protected]> | 2024-02-15 17:35:32 -0800 |
| commit | 8a8d2ed66fcaf7a6a66c92219b4f8a628f7c9392 (patch) | |
| tree | 5e9415ce073b4df51662156a4ac287a48ed9e562 /Project1/c_array.cpp | |
| parent | included memset from string.h in c_array.cpp (diff) | |
| download | in-class-exercise-12-connormcdowell275-8a8d2ed66fcaf7a6a66c92219b4f8a628f7c9392.tar.xz in-class-exercise-12-connormcdowell275-8a8d2ed66fcaf7a6a66c92219b4f8a628f7c9392.zip | |
testing to set indexes > 101 to 0. but theres LITERALLY no instruction in the lecture about it.
once again.
Diffstat (limited to 'Project1/c_array.cpp')
| -rw-r--r-- | Project1/c_array.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/Project1/c_array.cpp b/Project1/c_array.cpp index 1423273..962c785 100644 --- a/Project1/c_array.cpp +++ b/Project1/c_array.cpp @@ -19,12 +19,16 @@ void DoubleArraySize(int*& array, size_t SIZE) } delete[] array; - array = newArray; - - + //memset(array, 0, SIZE * sizeof(array[100])); + //memset(array, 0, SIZE * sizeof(array)); SIZE *= 2; + //for (auto i = 102u; i < SIZE; ++i) + //{ + // memset(array, 0, SIZE * sizeof(array)); + //} + PrintArray(array, SIZE); } |