Question 5

AQA Computer Science June 2017 Paper 1AS8 marks

On the specification

5.1
3.1 Fundamentals of programming
5.2
3.1 Fundamentals of programming
5.3
3.1 Fundamentals of programming
5.4
3.1 Fundamentals of programming
Question text

5 5.1 Explain the benefits of defining FIELDLENGTH and FIELDWIDTH as named constants instead of using the actual values in the code. [2 marks] 5.2 Explain the purpose of the first selection structure in the subroutine SeedLands. [1 mark] 5.3 The simulation is to be refined to include another level of drought: a minor drought. There is a 1 in 3 chance of a severe drought, and a 1 in 3 chance of a minor drought. If there is a minor drought, then one in four plants will die. Describe the changes that need to be made to the subroutine SimulateSummer in order to simulate a minor drought. You are not expected to make any changes to the Skeleton Program. [3 marks] 5.4 State the type of arithmetic operation carried out in the subroutine CreateNewField when the variables Row and Column are assigned new values outside the FOR loops. State the values calculated for Row and Column using the values of FIELDLENGTH and FIELDWIDTH that are specified in the Skeleton Program. [2 marks]