PLEASE HELP
Scenario An amateur meteorologist keeps a list of daily temperatures and wants a program to calculate how many times the maximum temperature occurred. For example, if the list of temperatures is [21, 24, 24, 23, 20, 19, 21, 24), the maximum of 24 occurs 3 times. a. Consider the problem of calculating how many times the maximum temperature occurs. i. What are the admissible inputs of the problem? ii. What is the output of this problem? (2 marks) b. Write three tests for this problem. The inputs should be different from the example given in the scenario description above. At least one of your tests must be a borderline case. Present the tests in a table, with a column for each input and output, and an extra column with a brief explanation of why you selected each test, as is done for example in Block 2 Part 2 Activity 2.10. (3 marks) c. Decompose the problem into sub-problems. Use the > notation and state in brackets the type of the problem and of each sub-problem, following the example in Block 2 Part 2 Activity 2.44. (6 marks) Show transcribed image text Scenario An amateur meteorologist keeps a list of daily temperatures and wants a program to calculate how many times the maximum temperature occurred. For example, if the list of temperatures is [21, 24, 24, 23, 20, 19, 21, 24), the maximum of 24 occurs 3 times. a. Consider the problem of calculating how many times the maximum temperature occurs. i. What are the admissible inputs of the problem? ii. What is the output of this problem? (2 marks) b. Write three tests for this problem. The inputs should be different from the example given in the scenario description above. At least one of your tests must be a borderline case. Present the tests in a table, with a column for each input and output, and an extra column with a brief explanation of why you selected each test, as is done for example in Block 2 Part 2 Activity 2.10. (3 marks) c. Decompose the problem into sub-problems. Use the > notation and state in brackets the type of the problem and of each sub-problem, following the example in Block 2 Part 2 Activity 2.44. (6 marks)
Expert Answer
Answer to Scenario An amateur meteorologist keeps a list of daily temperatures and wants a program to calculate how many times the…