ExamBank Scot · N5 Computing Science question bank · All N5 Computing Science questions
11 marks · Development process and analysis
Complete the analysis for the app by identifying the inputs and the output. Inputs Process Add up the scores Output The following user interface is designed for the player to enter their score for each hole. app Sanya Abioye 25/05/2023 Enter score Hole: Previous Hole Enter a score of if you did not finish a hole 1 2 3 4 5 6 7 8 9 Click below once all 9 scores have been entered Give two reasons why this user interface design is not fit for purpose. Reason 1 Reason 2 Each hole has a target score known as the par value. If a score entered is three or more above the par value for that hole it is adjusted to the par value plus two. This is shown below for holes 3 and 6. Hole 1 2 3 4 5 6 7 8 9 Total Score Par 3 4 4 4 4 3 4 4 5 Score 3 4 9 4 6 6 4 5 5 46 Final score 3 4 6 4 6 5 4 5 5 42 Part of the code for the app is shown below. … Line 10 REPEAT 9 TIMES Line 11 RECEIVE par FROM (INTEGER) KEYBOARD Line 12 RECEIVE score FROM (INTEGER) KEYBOARD Line 13 < calculate final score for each hole > Line 14 < update totalScore > Line 15 END REPEAT Line 16 SEND totalScore TO DISPLAY … Using a programming language of your choice, write the code for line 13. The final scores are stored within the app. State the most suitable data structure and data type for storing the final score for each hole. Data structure Data type The app uses the following bit-mapped graphic. Describe how a bit-mapped graphic is represented in a computer system’s memory. A 9-hole golf course is introducing an app to replace paper scorecards. The total score is the number of times the player hits the ball to complete all 9 holes. Below is an example of a paper scorecard that a player has filled in. Name: Date: Hole Score 1 2 3 4 5 6 7 8 9 Total score
One mark each for: • three inputs - score (for each hole) - name - date • output - total score Do not penalise any additional answers for input and output. One mark each for any two from: • no next hole button/enter • no zero button • no submit button • no delete/backspace to delete score One mark for the following code: • if (statement) • correct condition - score >= par + 3 • par + 2 assigned Alternative conditions could include: • score > par + 2 • score - 2 > par • score – 3 >= par One mark each for: • data structure - (1-D) array • data type - integer One mark each for: • each pixel • is stored as a binary value (bits)