Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

C++ Question Needs Aswers

I need help with this question, please. I'm a beginner.

Question: Write a function change that accepts an int array as the first parameter, and another int parameter for the length of that array and an int value as a third parameter. The function will store the integer value into the last element of the array. The original array SHOULD change. As an example, given the array
int x = {5, 4, 9, 42};
The following call to your function change
change(x, 4, 14);
should change the value of the last element of the array to 14.

Comments

Sign In or Register to comment.