Question: Provide a high-level decomposition. This should do no more than break the problem into the main subproblems. It is a description of what the solution

  1. Provide a high-level decomposition. This should do no more than break the problem into the main subproblems. It is a description of what the solution needs to do, without going into the detail of how it will be done. As a rather fanciful example, if you were planning a mission to collect rock samples from the Moon a high-level decomposition could be

    > Collect Moon rocks

    >> Fly to Moon

    >> Land

    >> Collect rock samples

    >> Return to Earth

    As you see this leaves out all the detail of things like distances and velocities and just gives the big picture. Of course, your decompositions will be very different, but we hope the example gives a feel for the level of detail appropriate in a high-level decomposition.

  2. Say what the inputs and outputs of the problem are.
  3. Write two tests for the problem. 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 in Block 2 Part 2 Activity 2.10, for example).
  4. Identify which of the TM112 pattern or patterns should be applied to the solution of the problem. State clearly the name of the pattern and the pattern number, for example "List generation Pattern 2.2". A list of all the patterns can be found in the Problem solving and Python quick reference .
  5. Write an algorithm for the problem by instantiating the pattern you have chosen.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!