To make use of our new Summarize function, we're going to add some code between the Main() curly braces. Type the following:
double[] arr = { 1, 5, 3, -6, 3, 6 };
Here, we're just creating a simple array and initializing it with a set of values. It doesn't really matter what they are, and I've included a negative value here for fun. Terminate this with a semicolon. Now that we have our test array, we can go ahead and run our Summarize function on it. On the next line, type the following:
Summarize(arr, out double sum, out double average);
We're passing in our new arr array that we've already set to the correct double type, and we're also declaring our two out variables.
Notice that in previous versions of C#, these variables would have to be declared outside of this function call, above it. In this case, because we...