









Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!










ASSIGNMENT 2 FRONT SHEET Qualification BTEC Level 5 HND Diploma in Computing Unit number and title Unit^ 0:^ Write^ a^ program^ and^ test Submission date 06/03/2022 Date Received 1st submission Re-submission Date Date Received 2nd submission Student Name Au Lam Thanh Dat Student ID GCS Class
Assessor name Le Ngoc Thanh Student declaration I certify that the assignment submission is entirely my own work and I fully understand the consequences of plagiarism. I understand that making a false declaration is a form of malpractice. Student’s signature Dat Grading grid P4 P5 M3 M4 D
Unit Number and Title Procedural Programming Academic Year 2021 Unit Tutor Le Ngoc Thanh Assignment Title Analysis and Design a solution for procedural programming problem Issue Date Submission Date IV Name & Date Learning Outcomes and Assessment Criteria Pass Merit Distinction LO3 Be able to implement procedural programming solutions LO4 Be able to test procedural programming solutions P4 Write a program that implements the designed solution. M3 Program is written following coding standards, input data are validated D2 Evaluate your program, state lessons learnt and future improvements. P5 Test the program with proper test plan. M4 Analyse test results for future maintenance.
Assignment Brief Scenario: Please refer to scenario in Assignment 1. Tasks 1 Your next task is to implement the software that you designed in previous steps. You need to implement the software designed in assignment 1 using C programming language. Your code must make use of programming standards, including file headers and effective code commenting. You need to provide screenshots of your program when running. During the development of your program, if you make any changes to the original design, state them with reasons in report. Your code listings must be included as an appendix. Task 2 Test your program by making a test plan, execute it and log results. Your test plan should include data validation and program operations based on requirements. Test results (passed or failed) should be analysed to help the program in future maintenance. Task 3 Write an evaluation and conclusion of the whole development. The evaluation of your program should be based on its running and its test result. You should mention about lessons learnt and future improvement. Also evaluate how procedural programming is applied in your program, state benefits, disadvantages or difficulties. A final report of these 3 tasks must be submitted in PDF format to CMS. Submission Format The submission is in the form of a Word document. You are required to make use of appropriate structure, including headings, paragraphs, subsections and illustrations as appropriate, and all work must be supported with research and referenced using the Harvard referencing system.
Figure 1: Choose option illustration In the menu choice, the user may select the option they desire. Explanation: Figure 2: Set up variables <stdio.h>: Provides the foundation for C's input capabilities. <string.h>: To accommodate a wide range of character sets
Figure 3: Do-while and Switch-case function. This program's Do – while function will return if the user completes their selection, for example, if the user selects number 1 to add a student and then returns to the main menu to add another student. While doing so, simply repeat the user's behavior. If the user completes their activity, the switch – case function in this program will switch to the next case. For example, if the user selects number 1, the program will return to the main menu, where the user may select number 2 (add student Id), number 3 (add student grade), and so on.
2. Display student list: Figure 4: Display learner illustration
4. Find student’s lowest grade: Figure 6: Output lowest grades illustration Explanation: The system will locate and present the data of the student with the lowest grade. Using "For" to display the lowest grade of a student on the screen. 5. Menu option: Figure 7: Menu option illustration Explanation: In main menu, there are 5 options for user to choose: (1) Input: the user enters information about the student, such as name, ID, and grade. Furthermore, these records are saved and may be examined using the next option. (2) Printall: data may be seen by selecting output all, and each student's name, id, and grade will be displayed on the monitor.
(3) Printhighest grades: after entering the information for each student, the data will be sorted as highest grades, with the highest grades belonging to the student with the highest grade (included ID and name). (4) Printlowest grades: this data will be ordered as lowest grades for students who have the lowest grade (included ID and name). (5) Exit: If the user has finished making their selections, hit 5 to exit the software. (6) Please select an option: the user types 1 -> 5 to select the alternatives they desire.
3. Find student’s highest grade: **Figure 10: Output highest grades result function
Test numbe r What is being tested Expected Outcome Actual Outcome (^) Pass or Fail 1 Select number 1 from menu Display screen for ID and Grade input. Input student’s ID. Input student grade. Pass 2 Select number 2 from menu Display screen with ID, Grade, and student information input. Output student’s ID. Output student grade. Output student’s information. Pass 3 Select number 3 from menu Students' greatest grades can be found and printed on the display screen. Find student’s highest grade. Print student’s highest grade. Pass 4 Select number 4 from menu Students' lowest grades can be found and printed on the display screen. Find student’s lowest grade. Print student’s lowest grade. Pass 5 Select number 5 from menu Display^ screen^ to allow number 5 to be entered to export the application, and if users enter the erroneous menu number, we will recommend that they enter the information again. The software was exported when number 5 was entered. However, if the user selects a different number of menus, the user will be required to re-enter information. Pass 6 Input ID: 1 Input student Grade = 5 Create an array with the student's ID and grade. Student ID: 1 Grade = 5 were stored into array Pass