[Solved] Normal 1 Spac Heading1 Hea Font Paragraph Name Date Course Csc 170l Section Week 15 Lab Fi Q37296652
How to do this is in C++ Program?


Normal 1 No Spac… Heading1 Hea Font Paragraph Name: Date Course: CSC 170L Section Week 15 Lab-Final Exam Lab CSC 170L Computer Programming Lab Write a C++ program called your LabWk15 First Name lastName.cpp which uses FUNCTIONS to perform each of the requirements below. When you are done you will upload it to Blackboard and hand in this printout, as well as a printed copy of the C++ program. To receive full credit, your code (Steps 3-11) must be implemented using functions, it must compile and run, and it must produce the correct input. You must also put a comment that indicates which step you are implementing above the code. For example,ー//step.. Step 0: Start a project and name your source file Week15Final FirstName LastName.cpp Step 1: Enter the skeleton code into your source file #include iostream> #include <string> using namespace std; int main () <insert code for the lab here> system(“pause”) return 0; Step 2: The main function should declare and initialize an array called finArray that has the following values: 3.3 4.4 5.5 5.6 6.77.8 8.9 9.1 1.1 2.2 tinArray Step 3: A function printValues that prints all of the elements in the array to the screen with appropriate label. Step 4: A function changeValues that changes all elements with values larger than 5.5 to (the value of the element + 2.1) using a loop and an “if” statement. Step 5: A function printValues that prints all of the elements in the array to the screen with appropriate label. Step 6: A function sumAvg to calculate the average of the array and print the sum and average on the screen with labels Step 7: A function sumOddindex that prints the sum of all the numbers at odd indices in the array (with an appropriate message). for e.g. if the array has 5 as the first element, 10 as the second element, 15 as the third element, 20 as the fourth element and 25 as the fifth element, the function should print the sum of 10 and 20. (Draw a picture to visualize this) Step 8: A function getUserinput to allow the user to change specific values in the array (until they desire to stop). Ask the user to enter which component they want to change and the new value. Hint: Think about how the code would look if the user wanted to change the third component to 9.9; what should that code look like? Now, repeat it. Step 9: A function printValues that prints all of the elements in the array to the screen with appropriate label. 1 words Kinsert code for the lab here> system (“pause”); return 0; 2: The main function should declare and initialize an array called finArray that has the following values: 2.2 T 3.3 T -4,4 T 5.5 – 5.6 – 6. – 7.8 – 8.9 — 9.1 1.1 f İnAr ray step 3: A function printvalues that prints allof the elements in the array to the screen with appropriate label. hangevalues that changes all elements with values larger than 5.5 to (the value of the element +2.1) using a loop and an “if statement. Step 5: A function printValues that prints all.of the elements in the array to the screen with appropriate label. step 6: A function sumAvg to calculate the average of the array and print the sum and average on the screen with labels. Step 7: A function sumOddindex that prints the sum of all the numbers at odd indices in the array (with an appropriate message). for e.g. if the array has 5 as the first element, 10 as the second element, 15 as the third element, 20 as the fourth element and 25 as the fifth element, the function should print the sum of 10 and 20. (Draw a picture to visualize this) Step 8: A function getUserinput to allow the user to change specific values in the array (until they dèsire to stop). Ask the user to enter which component they want to change and the new value. Hint: Think about how the code would look if the user wanted to change the third component to 9.9; what should that code look like? Now, repeat it. Step 9: A function printValues that prints all of the elements in the array to the screen with appropriate label. Step 10: A function printReverse that prints out all of the elements in the array in reverse order on the screen with appropriate label. Step 11: The main function should call all the functions. Some functions may be called more than once. ords Show transcribed image text Normal 1 No Spac… Heading1 Hea Font Paragraph Name: Date Course: CSC 170L Section Week 15 Lab-Final Exam Lab CSC 170L Computer Programming Lab Write a C++ program called your LabWk15 First Name lastName.cpp which uses FUNCTIONS to perform each of the requirements below. When you are done you will upload it to Blackboard and hand in this printout, as well as a printed copy of the C++ program. To receive full credit, your code (Steps 3-11) must be implemented using functions, it must compile and run, and it must produce the correct input. You must also put a comment that indicates which step you are implementing above the code. For example,ー//step.. Step 0: Start a project and name your source file Week15Final FirstName LastName.cpp Step 1: Enter the skeleton code into your source file #include iostream> #include using namespace std; int main () system(“pause”) return 0; Step 2: The main function should declare and initialize an array called finArray that has the following values: 3.3 4.4 5.5 5.6 6.77.8 8.9 9.1 1.1 2.2 tinArray Step 3: A function printValues that prints all of the elements in the array to the screen with appropriate label. Step 4: A function changeValues that changes all elements with values larger than 5.5 to (the value of the element + 2.1) using a loop and an “if” statement. Step 5: A function printValues that prints all of the elements in the array to the screen with appropriate label. Step 6: A function sumAvg to calculate the average of the array and print the sum and average on the screen with labels Step 7: A function sumOddindex that prints the sum of all the numbers at odd indices in the array (with an appropriate message). for e.g. if the array has 5 as the first element, 10 as the second element, 15 as the third element, 20 as the fourth element and 25 as the fifth element, the function should print the sum of 10 and 20. (Draw a picture to visualize this) Step 8: A function getUserinput to allow the user to change specific values in the array (until they desire to stop). Ask the user to enter which component they want to change and the new value. Hint: Think about how the code would look if the user wanted to change the third component to 9.9; what should that code look like? Now, repeat it. Step 9: A function printValues that prints all of the elements in the array to the screen with appropriate label. 1 words
Kinsert code for the lab here> system (“pause”); return 0; 2: The main function should declare and initialize an array called finArray that has the following values: 2.2 T 3.3 T -4,4 T 5.5 – 5.6 – 6. – 7.8 – 8.9 — 9.1 1.1 f İnAr ray step 3: A function printvalues that prints allof the elements in the array to the screen with appropriate label. hangevalues that changes all elements with values larger than 5.5 to (the value of the element +2.1) using a loop and an “if statement. Step 5: A function printValues that prints all.of the elements in the array to the screen with appropriate label. step 6: A function sumAvg to calculate the average of the array and print the sum and average on the screen with labels. Step 7: A function sumOddindex that prints the sum of all the numbers at odd indices in the array (with an appropriate message). for e.g. if the array has 5 as the first element, 10 as the second element, 15 as the third element, 20 as the fourth element and 25 as the fifth element, the function should print the sum of 10 and 20. (Draw a picture to visualize this) Step 8: A function getUserinput to allow the user to change specific values in the array (until they dèsire to stop). Ask the user to enter which component they want to change and the new value. Hint: Think about how the code would look if the user wanted to change the third component to 9.9; what should that code look like? Now, repeat it. Step 9: A function printValues that prints all of the elements in the array to the screen with appropriate label. Step 10: A function printReverse that prints out all of the elements in the array in reverse order on the screen with appropriate label. Step 11: The main function should call all the functions. Some functions may be called more than once. ords
Expert Answer
Answer to Normal 1 No Spac… Heading1 Hea Font Paragraph Name: Date Course: CSC 170L Section Week 15 Lab-Final Exam Lab CSC 170L … . . .
OR

