(1) Write a function named reverse that takes an integer array and its length as arguments and reverses the array in place. In other words, if int a[4] = {20, 40, 60, 80} initially, then after the call reverse(a, 4), the elements of a are now {80, 60, 40, 20} respectively. Note, the function should not return a value. (2) Write a function that takes a double-number array and its length as arguments. The function should replace the contents of each cell with the sum of the contents of all the cells in the original array from the left end to the cell in question. For example, if the array passed to the function looks like {2.4, 3.5, 2.5, 8.0}, then when the function returns, the array will have been changed so that it looks like {2.4, 5.9, 8.4, 16.4}, since 2.4+3.5=5.9, 2.4+3.5+2.5=8.4, etc. Note, the function should not return a value. (3) Write a function named index_of_minimum_value that takes an integer array and its length as arguments. The function should return as its value the subscript of the cell containing the smallest of the values in the array. For example, if the array that's passed to the function looks like {20, 30, 10, 50, 15}, the function should return the integer 2 as its value. (4) Write a function named sum that takes a double-number array and its length as arguments. The function should return as its value the sum of the numbers values in the array. For example, if the array that's passed to the function looks like {2.4, 4.2, 5.0, 1.4}, the function should return 13.0 as its value. (5) Write a function named right_rotation that takes a double-number array and its lengths as arguments. The function should shift the contents of each cell one place to the right, except for the contents of the last cell, which should be moved into the cell with subscript 0. For example, if the array that's passed to the function looks like {2.4, 4.2, 5.0, 1.4}, then when the function returns, the array will have been changed so that it looks like {1.4, 2.4, 4.2, 5.0}. Note, the function should not return a value. (6) Write a function which takes a two-dimensional double-number array and its lengths as arguments (i.e., float max(float a[N][M])). The function prints the largest element in the entire array. For example, if the array that's passed to the function looks like array[2][3] = {{3.2, 2.4, 4.2}, {2.7, 5.0, 1.4}}, then the function prints “5.0”. (7) Write a function named powers_of_2 which takes a two-dimensional integer arrays and its lengths as arguments (i.e., void powers_of_two(int a[N][M])) and replace the contents of each cell with powers of 2. The function should calculate 2^n (n is the value of each index) and replace the each element with calculated value. For example, if the array that's passed to the function looks like a[2][3] = {{1,2,3},{2,3,4}}, the function should replace {{2,4,8},{4,8,16}}. (8) Write a function that takes two double-number arrays and its length as arguments. The function should calculate the difference between the same elements of arrays and print the sum of the calculated floating values. For example, if two arrays that's passed to the function looks like {0,1,2,3}and {3,4,5,6}, the function should print "12". Note, the two arrays are the same size. (9) Write a function that takes a character array and returns a boolean: true if the character array is a palindrome and false if it is not. A palindrome is a word that is spelled the same way backwards as it is forwards. For instance, "mom" is a palindrome and so is "racecar" but "tophat" is not. (10) Write a function which takes a character array, a "delimiter" character and returns the position of the n^th "word" in the array such that words are separated by the delimiter character. For instance, say we had the character array like: char words[] = {'t','h','e',' ','q','u','i','c','k',' ','b','r','o','w','n',' ','f','o','x'}; And called the function like: int pos = token(words,' ',2); Then pos would contain 4 because that's the position of 'q' in the words array, which is the start of the second word when words are separated by a space character. Similarly if we had: char words[] = {'A','T','-','G','C','-','C','G'}; int pos = token(words,'-',3); pos would contain 6, the position of the start of the third hyphen-separated string. If there is no n^th word in the array, or no delimiters, or any other not-found condition, the function should return -1. (11) Write a function called substring, which given a character array, and a start position and length, fills a second array with the substring starting at that position that is the given length. For instance: char thing[] = {'s','o','m','e','t','h','i','n','g'}; int len = 2; char result[len]; // the result must be this big substring(thing,result,3,len); After which, the result array would contain {'e','t'}. (12) Write a function that takes an array of integers and the array size as parameters. The function has a third parameter, an integer called value. After running the function, all of the elements of the array are set to value. (13) Write a function that takes as arguments an array of integers and the length of the array. The function uses a selection sort to rearrange the numbers in the array so that they are sorted from smallest (at index [0]) to largest (at the final index). (14) Write a function that takes as arguments an array of integers and the length of the array. A third parameter is an integer called target. The function returns the index of the first location in the array that contains the target. If there is no such location, then the function returns the size of the array. (15) Rewrite the previous function so that it works by a binary search. (16) Write a function with this prototype: void interleave(int n, double a[], double b[], double c[]); Both a and b are arrays of length n, and c is an array of length 2n. The function copies the elements of a into the even indexes of c (c[0], c[2], c[4],...) and it copies the elements of b into the odd indexes of c (c[1], c[3], c[5],...). (17) Write a function that has one parameter, a 3x3 array of characters. The function returns true if one of the rows, one of the columns, or one of the diagonals has three identical characters in a row. Otherwise, the function returns false. (18) Write a function that has two parameters: an array of characters and the length of the array. The function returns true if all characters in the array are identical. Otherwise, the function returns false. (19) Write a function with this prototype: bool search(char data[], int n, char pattern[], int m); The function returns true if the m characters of the pattern appear in some consecutive locations within the n-character data array. (20) Write a function that takes an array of integers, the size of that array, and an integer x as parameters. The function should add the integer to each element of the array. (21) Write a function that takes a double array and its size as parameters and returns true if any element of the array is less than 42. (22) Print every value in an array that is greater than 10 but less than 40. (23) Write a function that takes an array of strings and the array’s size as parameters and prints out each element of the array. They should be followed by spaces, except for the last element, which should be followed by a period. (24) Write a function to find the average of all numbers in an array. (25) Write a function that uses a binary search to determine whether the number 42 exists in an array. Solutions to some of these problems are online in http://www.portmain.com/intro/exams/csci1300-exam3-practice.cxx