...
- Define the type of lists of posn-s.
- Write the templates of lists of posn-s. (NB: There are two non-primitive types here, one inductive the other a structure. So this writing a program that processes a list of positions may require two templates or one, depending on if you believe in structure templatesusing two templates; a template for lists of posn-s and a template for processing posn-s. If you need to use two templates, you _also need to write two functions, one to process a list of positions and one to process positions.)
- Write the function
positive-quadrant?
, which takes in a singleposn
and returns true only when its components are both positive. - Develop
count-positive-quadrant
, which takes a list of posn-s and returns a count of those in the upper-right quadrant. - Develop
filter-positive-quadrant
, which takes a list of posn-s and returns a list of those in the upper-right quadrant.
...