Question: C-programming CSCI 1110 - Lab 6 -Top-down Design In this lab you will get some experience at doing top-down design as you develop the solution
C-programming
CSCI 1110 - Lab 6 -Top-down Design In this lab you will get some experience at doing top-down design as you develop the solution to the problem below. The instructor will assign teams. 1 The Problem Pretend that you have a small group of people in a room. For each person you have their name, gender and their salary. You want to make a small report. This report is composed of two parts. Part 1 is a list of the top five earning females in the room, listed from the highest to lowest salary. The second part is a list of the bottom five earning males in the room, listed from lowest to highest salary. Each part of the report should have a proper heading and print out the persons name in one column and their salary in a second column. A third column should indicate whether the persons salary is above or below the average salary of the people of the opposite gender in the room. 2 The Database You should create a simple database of up to 20 peoples information in three parallel arrays. Each persons name should only be a single character long. Gender should be a single character, M or F. The teacher will provide the array for salaries. The data for your arrays for the names and the gender should be read from the user. You should stop entering data either when 20 people have been processed or if a ? is entered as someones name. All groups will be using the same database. Assign one person of your group to meet with the other groups to create this database. 3 Top-down Design Develop an outline of the steps involved in this solution (Hint: it might be easier to divide the data into gender groups). Also create a set of test data. Then divide up the steps and assign work to each of the members of the team, so that each person is responsible for writing at least one function. Make sure you know the types of information that each function should receive and return. You can use any ideas or code in the text book or the lecture notes. Once each person has been assigned work, go to separate computers and write the code for your part. Then bring all of the parts back together and make whatever modifications are necessary to get the program working correctly. 4 To Turn In Each person should turn in the code that they wrote for their part. Also turn in the final version of the complete program with the output obtained for your test data set and a Microsoft Word document describing what each person did and what issues were found and fixed during the creation of the lab. The number of issues will not be any bearing on the grade given by the instructor.
Use this array for the salaries:
int salaries[20] = { 20000,25000, 25000, 30000, 30000, 35000, 40000, 42000, 43000, 44000, 45000, 50000, 55000, 60000, 65000, 65000, 67000, 70000, 80000, 85000};
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
