Tim Steenvoorden, JurriÃ«n Stutterheim, Erik Barendsen, and Rinus Plasmeijer. Visual Support for Learning Monads. Technical report: ICIS-R17001, January, Radboud University Nijmegen, 2017.
Monads are an important topic in functional programming. In Haskell, for example, monadic I/O is the only way to perform I/O at all. However, newcomers to functional programming, such as bachelor students, often struggle with learning about monads. In other domains, graphical formalisms such as Venn diagrams or commutative diagrams are often used to support students with a visual learning preference in learning new concepts. Previously, we have developed a novel tool, called Tonic (Task-Oriented Notation Inferred from Code) that generates a graphical representation of the monadic structure of Clean programs, akin to flow diagrams. Tonic is integrated in the Clean compiler, allowing us to automatically generate these blueprints from code. In this paper we describe and evaluate how we have used blueprints to help a group of second year bachelor`s students learn about monads. We have found that using blueprints in the lecture slides and in the assignments have a positive impact. Visually oriented learners tend to appreciate blueprints, but tend to look at given blueprints rather than constructing them themselves. Exam marks are on the same level or better than previous years, indicating students` performance is not negatively affected. We conclude that Tonic should be developed further, such that students can generate blueprints during code development.