Hello, I am new to C++ and I am,stuck on this question I received from my professor, does anyone mind helping me out? Thank you in advance.
Write a program that can be used to gather statistical data about the number of movies college students see in a month. The program should perform the following steps:
Ask the user how many students were surveyed. An array of integers with this many elements should then be dynamically allocated using the new operator.
Allow the user to enter the number of movies each student saw in a month into the array.
Calculate and display the average, median and mode of the values entered.
That is your homework for the sole purpose that you learn by doing. The instructions have useful details and imply also that your professor has already described you all the necessary language constructs.
Split the whole into smaller and simpler subtasks and attack each separately.
When you have done your best effort, then show us your code and ask specific questions about it. There we can help you.
Well to give some tips, from what I see you would need a string array? Then make an array with just as many entries (example: 5 students = 5 int array). You'll need a for loop to get in the amount of movies each student saw.