Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

you may design either a console application or a GUI application. Design a program named ContestantDemo that contains a contestant class that has public static

you may design either a console application or a GUI application. Design a program named ContestantDemo that contains a contestant class that has public static arrays that hold talent codes and descriptions. The talent descriptions are Singing, Dancing, Musical Instrument, and Other. The talent codes are S, D, M, and O. The class should contain fields for the contestants name. The class should contain fields for a talent code and description. The set accessor for the code assigns a code only if it is valid. Otherwise, it assigns I for Invalid. You should create a method that performs this task. The talent description is a read-only property that is assigned a value when the code is set. Include a field that holds the entry fee for each category and get and set accessors. Extend the Contestant class to create three subclasses, ChildContestant, TeenContestant, and AdultContestant. Child contestants should be 12 and younger and their fee is $15, Teen contestants should be between 13 and 17 and their fee should be $20. Adults are 18 and older and their entry fee should be set to $30. The fee should be set for each class. Override the ToString() method in each class and return a string that includes all the contestant data, including the age category and the entry fee. Prompt the user for the number of contestants in this years competition, which must be between 0 and 30. The program should continue to prompt the user until a valid value is entered. The program prompts the user for the names, ages, and talent codes for the contestants entered. Along with the prompt for a talent code, display a list of valid categories. Based on the age entered for the contestant, create an object of the correct type (adult, teen, or child), and store it in an array of Contestant objects. After the data entry is complete, display the total expected revenue, which is the sum of the entry fees for the contestants. After data entry is complete, display the valid talent categories and then continuously prompt the user for talent codes, and display all the data for all the contestants in each category, this should be completed in a method. Display an appropriate message if the entered code is not a character or valid code. Create the UML diagram for the above. Write the code for the above in Visual Studio using C#. Explain your development steps.

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

Beyond Big Data Using Social MDM To Drive Deep Customer Insight

Authors: Martin Oberhofer, Eberhard Hechler

1st Edition

0133509796, 9780133509793

More Books

Students also viewed these Databases questions