Create an AddOneToAll function so that it correctly adds one to each element in an array with 5 elements: Compile your code with a Linux compiler and execute the output file. "./"
int array [5];
addOneToAll(array, 5);
}
void addOneToAll ( int * array, int count) { //add one to all
for (int x = 0; x<count; x++) {
array[x] = array [x] + 1;
}
// I understand that there are other ways of doing this and I am open to all constructive criticism, but before you comment please consider that this code is written so the built-in Linux compiler (g++) can understand it.