Skip to main content
A-LevelComputer ScienceAlgorithm design and problem-solving9618/23 · Oct/Nov 2022 · Q35 Marks

An algorithm is needed to process a sequence of numbers. Numbers may be positive or negative and may be integer or decimal. The algorithm will: • prompt and input one number at a time until the value zero is input • sum the negative numbers • sum the positive numbers • when zero is input, output the two sum values and then end. Describe the algorithm needed. Do not include pseudocode statements in your answer.

  1. An algorithm is needed to process a sequence of numbers. Numbers may be positive or negative and may be integer or decimal. The algorithm will: • prompt and input one number at a time until the value zero is input • sum the negative numbers • sum the positive numbers • when zero is input, output the two sum values and then end. Describe the algorithm needed. Do not include pseudocode statements in your answer.[5]

Mark scheme

Marking points from the official mark scheme (Oct/Nov 2022). The mark or mark type is shown in brackets.

  1. [5] One mark per point, for example: 1 Declare two (REAL) variables for the two sum values AND initialise both to zero 2 Prompt AND Input a number 3 If number greater than zero add to positive sum and If number less than zero add to negative sum 4 Repeat from step 2 if number not zero 5 After loop the Output SumPos and SumNeg

Write your answer and get it marked

On Oracle Prep you can write or photograph your own answer and have it marked by AI against this mark scheme, with feedback on what you missed.

Sign up free →

About this question

Topic
Algorithm design and problem-solving, A-Level Computer Science (syllabus 9618). Structured question, 5 marks.
Source
A-Level Computer Science, Oct/Nov 2022 Paper 2 Variant 3, question 3.

Questions and mark schemes are from past examination papers and remain the copyright of the exam board. How Oracle Prep builds its content

Related Computer Science questions

© 2026 Oracle Prep