Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a C + + program that resembles a TV show categories rating application. This program, which incorporates a simple menu, should allow the user

Write a C++ program that resembles a TV show categories rating application. This
program, which incorporates a simple menu, should allow the user to perform the
following based on the operation of choice, with specific data/values of essential use in
the program to be read from the user:
1. Choosing number (1) will allow the user to select one of the TV show categories
to rate from a different sub-menu: (1- Horror, 2- Sci-Fi,3- Drama).
2. Choosing number (2) will allow the user to enter their ratings according to their
chosen age group which are also chosen from a sub menu, prior to rating entry.
3. Choosing number (3) will allow the user to remove a previously made rating
according to the specified category.
4. Choosing number (4) will produce two ordered list (in ascending and descending
orders) of the ratings made for each category and age group.
5. Choosing number (5) will display all average ratings made of all age groups and
categories.
6. Choosing number (6) will allow the user to search for a specific rating range within
any of the aforementioned categories.
7. Choosing number (7) will allow the user to view a list of the highest ratings made
(between [95-100]) based on the recentness of the entry (recently-entered data
are shown first).
8. Choosing number (8) will generate a status report of the categories and age groups
with the most ratings and the total number of ratings received per category.
9. Choosing (0) would cause the program to terminate.
Please take the following criteria into consideration:
Show the menu as many times as possible until the user decides to exit.
A fixed rating range should be used for each category and ratings should be within the
range of [1-100]. Any rating above or below this range should not be accepted.
To cast a rating, the user will have to specify the age group, age groups are as follows:
o Below 18.
o From 1829.
o From 3044.
o 45 and above.
Upon choosing the age group, the user is then allowed to enter their rating within the
range of [1-100]. If a user chooses an unrecognized or out of range rating value, the
user is warned and prompted to enter the rating again.
Ratings should be saved in two different locations at once, for example: if a user goes
for the age category of 30-44 and makes a rating for the horror category, the same
rating is added to the category and to the age group data structures.
To remove a previously made rating, the user would have to specify the category and
the age group along with the rating value to be removed. Overwrite the previous rating
with a 0 to indicate the rating removal. Rating removals should be made from both the
category and the age group simultaneously.
Display the rating averages for all categories and age groups by listing the TV shows
category then the ratings made per each age group within the category.
To search for a specific rating within any of the categories or age groups, the user will
have to choose the search location then the starting range of rating to be searched
for. For example, a user can search for ratings above 50 from the age group of 30
44. Returned values will specify the rating list order (index) number and the rating
value.
Generate a new list that adds only the top ratings between the range of [95-100] based
on the recentness of entry, whereby the top ratings entries made last are displayed at
the start of the list and the less recent entries are shown at the end of the list.
Make sure to validate your input to avoid any out-of-range entry.
Make use of the proper data structures and algorithms to create this program.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Main Memory Database Systems

Authors: Frans Faerber, Alfons Kemper, Per-Åke Alfons

1st Edition

1680833243, 978-1680833249

More Books

Students also viewed these Databases questions

Question

an element of formality in the workplace between different levels;

Answered: 1 week ago