Question: need help where it says / / your code here Structures and Enumeration A . You are to write a program to do the followings:

need help where it says //your code here
Structures and Enumeration
A. You are to write a program to do the followings:
1. Define an enumeration type RefereeGrade including 5 values UNKNOWN, CLUB, STATE, NATIONAL and FIFA (given by instructor).
2. Define a structure named SReferee containing data members for the following information:
- Id (typed string)
-\(\quad \) First Name (typed string)
- Last Name (typed string)
- Grade (typed RefereeGrade)
Then, create an array of 10 elements typed SReferee and initialize this array (given by instructor).
3. Create a menu with the following options:
a. List all referees
b. List all referees of a specific grade
c. List all referees with grade lower than a specific grade
d. List all referees with grade higher than a specific grade
e. List information of a specific referee using the Id
f. List information of a specific referee using the first and last names
g. Add a referee
h. Remove a referee using first and last names
i. Update referee grade using Id
j. Quit
4. For all the listing options, the header needs to be displayed.
5. For options "List all referees", only list the referees with the id NOT "0000".(given by instructor)
6. For option "List all referees with grade ...", ask for that specific grade and then use operators \(==\),> or for comparison.
7. For option "Add a referee", find index of an available slot (i.e. ID is"0000"). If there is no slot available, raise an error message and return to the menu. If there is at least one, ask new referee information (id, names, grade) and then insert the information into that slot.
8. For option "Remove a referee", ask for referee first and last names and make sure it is not "None". Then, find the index of that referee in the list. If found, reset the information with the default value: "0000", "None", "None", UnKNOWN for id, first name, last name and grade respectively. Otherwise, raise an error message
need help where it says / / your code here

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!