subject

We will practice using pointers, declaring them, making them point to another variable, change the content of the referent, make the pointer point to something else, and write and use a function using pass by reference. There are two parts to this assignment, though not connected, but should be implemented in the same file to simplify. 1. Write code for a function that receives two parameters (a, and b) by value and has two more parameters (c and d) by reference. All parameters are double. The function works by assigning (a/b) to c and assigning (a*b) to d. From main, use scanf to get two numbers, then call the function, and then display both returned values to the output in a printf statement. 2. After part 1 is completed, write code to get 20 integer numbers from the user. The code then displays how many of those numbers are above the numbers average. To get proper credit you must follow these steps: a. write a for loop to fill the array with numbers from the user. Use a pointer b. use an index to pass through all array elements to calculate the average in another loop. c. write a function, then pass the array, its size, and the average to the function. The function returns the count of the number of elements that are above the average.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 15:00
Marissa is a high school student who wants to be a hydroelectric production manager. she talks to her guidance counselor about her education path, and the counselor says that she needs to get an associate’s degree from a four-year college and will follow that with significant on-the-job training. what error did the counselor make while advising marissa? marissa will not have on-the-job training. marissa also needs a three-year apprenticeship. marissa only needs to attend a two-year college. marissa needs a bachelor’s degree.
Answers: 1
question
Computers and Technology, 22.06.2019 15:30
To increase sales, robert sends out a newsletter to his customers each month, letting them know about new products and ways in which to use them. in order to protect his customers' privacy, he uses this field when addressing his e-mail. attach bcc forward to
Answers: 2
question
Computers and Technology, 22.06.2019 17:30
The forerunner to cell phones, pdas, and smartphones was
Answers: 1
question
Computers and Technology, 22.06.2019 19:30
Avariable definition defines the name of a variable that will be used in a program, as well as
Answers: 3
You know the right answer?
We will practice using pointers, declaring them, making them point to another variable, change the c...
Questions
question
Mathematics, 26.05.2021 19:50
question
Mathematics, 26.05.2021 19:50
question
History, 26.05.2021 19:50
question
Mathematics, 26.05.2021 19:50
question
Mathematics, 26.05.2021 19:50
Questions on the website: 13722362