Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Write a menu based program to maintain student records. Your program should take the following inputs: 1. Student first name (max. 20 characters) 2. Student last name, (max. 20 characters) 3. Student scores (float/double), eg. 85.4

Problem:

Write a menu based program to maintain student records. Your program should take the following
inputs:
1. Student first name (max. 20 characters)
2. Student last name, (max. 20 characters)
3. Student scores (float/double), eg. 85.4

Your program should be able to take records of a minimum of 5 students. After taking the records,
you should provide 8 functionalities to the user.
1. Print records - prints records of all students
2. Add a new record - take a new record from the user for a new student. Be careful, you may need
to allocate more memory using dynamic memory allocation.
3. Delete record(s) - to delete a record, ask for the last name of the student from the user. If there
are multiple students with same last name, you must delete all of their records. You must free up the
memory holding these records.
4. Search by last name - prints record of the student with a given last name. If there are multiple
students with the same last name, print records for all of them.
5. Sort by score - sort the records of students according to their scores, and then print the sorted
records.
6. Sort by last name - sort the records of students according to their names alphabetically, and then
print the sorted records.
7. Find the median score - compute the median score and print it. Also, print how many students are
above this median score.
8. Exit the program - terminate on a specific input from the user. Let that specific input be an
integer of value 0.
You should print the record in the following format:
First Name: firstname 1, Last Name: lastname 1, Score: score 1
First Name: firstname 2, Last Name: lastname 2, Score: score 2
.
.
.

You should write each functionality from 1-7 in separate functions. You should provide a menu to
the user as following:
For inputs:
Please indicate number of records you want to enter (min 5):
#of records
After user gives the number of records, you should inform the user how to enter the records:
Please input records of students (enter a new line after each record), with following format
first name last name score
After user gives the inputs for the records, inform the user about the functionalities:
Print records (press 1)
Add a new record (press 2)
Delete record(s) (press 3)
Search by last name (press 4)
Sort by score (press 5)
Sort by last name (press 6)
Find median score (press 7)
Exit the program (press 0)
After user chooses a functionality, your program performs that and provides this menu again to
select another functionality. This goes on until user presses 0.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M9455193

Have any Question?


Related Questions in Computer Engineering

Question you are in a social situation talking with

Question : You are in a social situation talking with coworkers, friends, or family members who are not familiar with the concept of networking, except for the idea that they turn on their computer and surf the World Wid ...

A street vendor is asking people to play a simple game you

A street vendor is asking people to play a simple game. You roll a pair of dice. If the sum on the dice is 10 or higher, you win $10. If you roll a pair of 1's, you win $59. Otherwise you lose $5. If the random variable ...

The formulas a rarr b and c and a rarr b and a rarr c are

The formulas A → (B ∧ C) and (A → B) ∧ (A → C) are logically equivalent. For this problem, you are going to prove that they are equivalent in two different ways. Prove that A → (B ∧ C) ≡ (A → B) ∧ (A → C) by writing two ...

Are search algorithms tied to data structures being

Are search algorithms tied to data structures being searched, or can they be utilized in other scenarios?

Question suppose that you have 2 dfas and have 7 and 6

Question : Suppose that you have 2 DFAs and have 7 and 6 states respectively, and 3 and 4 final states respectively. If I built the product DFA for the intersection of their languages, how many final states will the resu ...

Regarding terminology for the quality of a picture explain

Regarding terminology for the quality of a picture, explain briefly What is a pixel? What is color depth? Higher is better or lower Search for purchasing a monitor, list the specifications (concentrate on the criteria th ...

Risk management and malicious attacks please respond to the

"Risk Management and Malicious Attacks" Please respond to the following: With regards to risk-response planning, there are four (4) responses to negative risks that an organization may pursue: avoid, transfer, mitigate, ...

Information systemsdirections answer the following if you

Information Systems Directions : Answer the following: If you were asked to develop a logical model of the registration system at a school, would it be better to use a top-down or bottom-up approach? Explain your reasoni ...

Compare remote authentication dial-in user service radius

Compare Remote Authentication Dial-In User Service (RADIUS) and Terminal Access Controller Access-Control System Plus (TACACS+).

Not many applications use this type of direct connection ex

Not many applications use this type of direct connection (ex: ftp, ssh, tenet, smtp, httpd, pop) anymore unless it is within the corporate firewall. Why do you think this is? Pick 1 or 2 as example.

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As