Write a program that read from the user id, names, and marks for a number of students.

computer science


Description Write a program that read from the user id, names, and marks for a number of students. The program then list all the students and allows user to search the list by giving a search key. This assignment will help you understand C pointers, characters, and strings. NOTE: do NOT use scanf in this assignment. Requirements The program will  REQ-1: read the total number of students from the user. Assume user’s input is a valid integer.  REQ-2: read id, name, and marks for each student, store into three arrays. Each record is given in a line of text, with id, name, and marks separated by a comma. Student id is an integer, name contains letters and spaces, and mark is a double value. Assume user’s inputs are in correct format.  REQ-3: print the list of students and the average mark. Student names are displayed in all-caps.  REQ-4: read any search key from the user, search students by name and display all records that contain the key in the name. Also display the average for the found records (display 0.0 if no record is found). Keep on searching until the user inputs a ‘q’ or ‘Q’, then exit the program. If the user wants to search a single letter ‘q’ or ‘Q’, the user will input “\q” or “\Q”. Grading Your submission will be evaluated based on the following criteria: Documentation 2 Code is well-commented and clearly explained Efficiency 4 Code uses the best approach and is efficient Functionality 34 Program works correctly and meets the requirements REQ-1 3 Number read; Three parallel arrays created for id, name, marks REQ-2 9 Number of records parsed and stored into the three arrays REQ-3 5 Each record is printed in a row; Last row displays the average REQ-4 17 Search key is read and used in searching with results printed Total Marks 40 *. Penalties may apply to cases when code doesn’t compile (-100%), program crashes while being tested (-50%), wrong submission or naming (-50%), late submission (-10% - -100%), submission instructions not followed (-10% - -100%), use of scanf, goto, global variables, or recursion (-10 - - 100%), etc. Submission Name your source code “assignment3_lastname.c”. Submit it to the SLATE Assignment 3 submission folder. Below are some sample runs that shows the format of your program's output (green text is used for the prompts created by the program; red text is used for the user's inputs; black text is the program's actual outputs. These colours are here for demonstration only; your program does not need to display in colour):

Related Questions in computer science category