Question
Modify the code to use functions. Create a getInput function, a calcTotal function and a displayResults function. The purpose of getInput is to prompt the
Modify the code to use functions. Create a getInput function, a calcTotal function and a displayResults function. The purpose of getInput is to prompt the user for input and assign values to the 2D array. The purpose of the caclTotal function is to process the 2D Array and accumulate the total sales. The purpose of the displayResults functionn is to display the entire 2D array for quarterly sales as well as the total sales. The main function should consist of variable declarations and function calls. Do not use global variables. Pass the data through functions parameters or value returning functions. Please help. Answer in C++ please.
2 #include
Step by Step Solution
There are 3 Steps involved in it
Step: 1
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