Question: Your task is to write a program that has a function. It should have these general characteristics: The program should not be longer than 30

Your task is to write a program that has a function. It should have these general characteristics:


  1. The program should not be longer than 30 lines. This should be a small task, nothing fancy.

  2. The program must contain a function.

  3. The task of the function is to be passed in a minimum of two variables and to change their value within the function.

  4. The main program will declare the variables (not global variables) and initialize them to some starting value, call the function, and print out the values of the variables after the function.

  5. You will need to have a prototype of the function.

The variables can be char, int, or float.
can you please comment out the reasons and steps of why and what you are doing?

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!