Question
1. write a function that will take input and array and return the minimum value of the array, the maximum value of the array, and
1. write a function that will take input and array and return the minimum value of the array, the maximum value of the array, and average of the array respectively. After the user enters the values of the array, use the functions to compute the min, max, and average of the array values.
2. Write a function that takes a string as an argument and removes the spaces from the string. Test it in a program that uses a loop to read lines until you enter an empty line. The program should apply the function to each input strong and display the result.
Objectives: 1) Learn to write functions that operate on arrays 2) Learn to manipulate strings using functions Description This programming assignment will have you write two programs. 1. The first program will be a modification of Assignment 3. Just as in Assignment 3, the user will input up to 20 numbers, and these numbers will be stored in an array. Write functions called arrmin, arrmax, and arraver that will take as input and array, and return the minimum value of the array, the maximum value of the array, and the average of the array respectively. After the user enters the values of the array, use the functions to compute the min, max, and average of the array values and print them out. 2. (Prata Chap. 11, Problem 10). Write a function that takes a string as an argument and removes the spaces from the string. Test it in a program that uses a loop to read lines until you enter an empty line. The program should apply the function to each input string and display the result. Deliverables: 1) Submit the C source code as an attachment to the TA Fernando Cervantes: and nohlant formantala minare utan adu Nama ya BEA 14 91
Step by Step Solution
3.48 Rating (141 Votes )
There are 3 Steps involved in it
Step: 1
Write a function that will take input and array and return the minimum value of the array the maximum value of the array and average of the array resp...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started