#include using namespace std; /* For all these: Don't use a loop! This includes using goto */ /* Return the sum of an array, given the length */ int sum(int *array, size_t length){ } /* Capitalize each letter in a null-terminated string */ void capitalize(char *str){ } /* Print out each item in the array, with some sort of separator */ void print_array(int *array, size_t length){ } /* Print out each item in the array, like above but backwards */ void print_array_backwards(int *array, size_t length){ } int main(){ int array[] = {100, 200, 300, 400, 500, 600, 700, 800, 900}; cout << "sum = " << sum(array, 9) << endl; char phrase[] = "Gerbils do not normally shout in the middle of the night"; capitalize(phrase); cout << "Phrase, capitalized: " << phrase << "\n"; cout << "Array: "; print_array(array, 9); cout << "\n"; cout << "Array backwards: "; print_array_backwards(array, 9); cout << "\n"; return 0; }