My question is for C programming. Write a complete program by using four helper functions The whole requested parts should be written in one single program. For all the functions, use the same prototype. Do not hard code any value, all the values must be given by the user in the whole code.  The first function is getting a string and prints the given string, use the same given prototype: void myname ( char firstlastname[ ]); when you test the program, you will call the function in the main, the input will be your name ( you will prompt the user) and the functions prints it completely. The second function which you will add to the program will take 3 integer values and return the average all the 3 integer values, use the same prototype which is given here: double ave ( int num1, int num2, int num3); Call the function in the main, ask the user for 3 values. Test case for 3 given values by the user: 3  5  2 The third function will accept an array of numbers and prints it in the reverse order. void ptr_r (int arr[ ]); for testing this part you will call the function in the main with array int test[5]; you will get values from the user, and the function ptr_r, prints that in the reverse order. User input for the test case is: 100  200  0  -99  22 And after the call it shows: 22  -99  0  200  100 The fourth function will find the max value in the array test[5], which user added before. int maxi( int arr[ ]); based on the given values from the user, when you call the function, it returns 200. At the end of the code, print the number of the characters, that you have added for the string ( your name) with the use of a function of string.h library. You should get one screenshot which shows all the functions and requested options work

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

My question is for C programming.

Write a complete program by using four helper functions The whole requested parts should be written in one single program. For all the functions, use the same prototype. Do not hard code any value, all the values must be given by the user in the whole code. 

The first function is getting a string and prints the given string, use the same given prototype:

void myname ( char firstlastname[ ]);

when you test the program, you will call the function in the main, the input will be your name ( you will prompt the user) and the functions prints it completely.

The second function which you will add to the program will take 3 integer values and return the average all the 3 integer values, use the same prototype which is given here:

double ave ( int num1, int num2, int num3);

Call the function in the main, ask the user for 3 values.

Test case for 3 given values by the user: 3  5  2

The third function will accept an array of numbers and prints it in the reverse order.

void ptr_r (int arr[ ]);

for testing this part you will call the function in the main with array int test[5];

you will get values from the user, and the function ptr_r, prints that in the reverse order.

User input for the test case is:

100  200  0  -99  22

And after the call it shows:

22  -99  0  200  100

The fourth function will find the max value in the array test[5], which user added before.

int maxi( int arr[ ]);

based on the given values from the user, when you call the function, it returns 200.

At the end of the code, print the number of the characters, that you have added for the string ( your name) with the use of a function of string.h library.

You should get one screenshot which shows all the functions and requested options work.

Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY