Skip to content

wanted: exercises on declarative graphics

new exercise type, using the Diagrams library https://archives.haskell.org/projects.haskell.org/diagrams/

  • instance: a picture (svg, png)
  • solution: an algebraic expression that, when rendered, produces the given picture.

variants:

  • fuzzy comparison with target (allow some deviations in pixel colour/position)
  • blueprint exercise (give part of the expression in the instance, student has to fill in holes)

references: Hudak: Haskell School of Expression ( https://www.cambridge.org/core/books/haskell-school-of-expression/70651D70E17ECC07C91D8487D2EFEAE7 ) uses declarative graphics for an introduction to programming.

what I do not want: imperative graphics (drawing commands in IO) (also not in some simulated form of IO). This exercise type should be about algebraic description of things.