Question: C++ functions and main functions. Ty 2-3. Given an array of integers, write a function to calculate the sum of the elements if it is

 C++ functions and main functions. Ty 2-3. Given an array of

C++ functions and main functions. Ty

2-3. Given an array of integers, write a function to calculate the sum of the elements if it is a palindrome array. If it is not a palindrome array, your function must return -2. Your function must call separate functions to check whether or not the array is a palindrome and to calculate the sum of its elements. If the length is O or negative each function must return -1 or false as its result. Signature: int sum_if_a_palindrome (int integers[], int length) Signature: bool is_a_palindrome (int integers[], int length) Signature: int sum_elements (int integers[], int length) 2-4. Given an array of integers, write a function to determine its maximum and minimum elements and then return their sum. Your function must call separate functions to identify the maximum and minimum elements. If the length is O or negative each function must return-1 as its result Signature: int sum_min_and_max(int integers[], int length) signature: int max_integer(int integers[], int length) Signature: int min_integer(int integers[], int length)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!