Hostname: page-component-8448b6f56d-m8qmq Total loading time: 0 Render date: 2024-04-25T00:06:06.793Z Has data issue: false hasContentIssue false

Understanding beginners' mistakes with Haskell

Published online by Cambridge University Press:  06 August 2015

VILLE TIRRONEN
Affiliation:
Department of Mathematical Information Technology, University of Jyväskylä, P.O. Box 35 (Agora), 40014, Jyväskylä, Finland (e-mail: ville.tirronen@jyu.fi, samuel.h.uusi-makela@student.jyu.fi, ville.isomottonen@jyu.fi)
SAMUEL UUSI-MÄKELÄ
Affiliation:
Department of Mathematical Information Technology, University of Jyväskylä, P.O. Box 35 (Agora), 40014, Jyväskylä, Finland (e-mail: ville.tirronen@jyu.fi, samuel.h.uusi-makela@student.jyu.fi, ville.isomottonen@jyu.fi)
VILLE ISOMÖTTÖNEN
Affiliation:
Department of Mathematical Information Technology, University of Jyväskylä, P.O. Box 35 (Agora), 40014, Jyväskylä, Finland (e-mail: ville.tirronen@jyu.fi, samuel.h.uusi-makela@student.jyu.fi, ville.isomottonen@jyu.fi)
Rights & Permissions [Opens in a new window]

Abstract

Core share and HTML view are not available for this content. However, as you have access to this content, a full PDF is available via the ‘Save PDF’ action button.

This article presents an overview of student difficulties in an introductory functional programming (FP) course taught in Haskell. The motivation for this study stems from our belief that many student difficulties can be alleviated by understanding the underlying causes of errors and by modifying the educational approach and, possibly, the teaching language accordingly. We analyze students' exercise submissions and categorize student errors according to compiler error messages and then manually according to the observed underlying cause. Our study complements earlier studies on the topic by applying computer and manual analysis while focusing on providing descriptive statistics of difficulties specific to FP languages. We conclude that the majority of student errors, regardless of cause, are reported by three different compiler error messages that are not well understood by students. In addition, syntactic features, such as precedence, the syntax of function application, and deeply nested statements, cause difficulties throughout the course.

Type
Articles
Copyright
Copyright © Cambridge University Press 2015 

References

Anderson, J. R., Pirolli, P. & Farrell, R. (1988) Learning to program recursive functions. In The Nature of Expertise, Robert, G., Chi, M. T. H. & Farr, M. J. (eds), Hillsdale: Psychology Press; ISBN-13: 978-0805804041, pp. 153184.Google Scholar
Bieniusa, A., Degen, M., Heidegger, P., Thiemann, P., Wehr, S., Gasbichler, M., Crestani, M., Klaeren, H., Knauel, E. & Sperber, M. (2008) HtDP and DMdA in the battlefield. Functional and Declarative Programming in Education. Victoria, BC, Canada.CrossRefGoogle Scholar
Blanco, J., Losano, L., Aguirre, N., Novaira, M. M., Permigiani, S. & Scilingo, G. (2009) An introductory course on programming based on formal specification and program calculation. ACM SIGCSE Bull. 41 (2), 3137.CrossRefGoogle Scholar
Bonar, J. & Soloway, E. (1985) Preprogramming knowledge: A major source of misconceptions in novice programmers. Human–Comput. Interact. 1 (2), 133161.CrossRefGoogle Scholar
Brown, N. C. C. & Altadmri, A. (2014) Investigating novice programming mistakes: Educator beliefs versus student data. In Proceedings of the 10th annual conference on International Computing Education Research. University of Glasgow, Glasgow, Scotland: ACM.CrossRefGoogle Scholar
Chakravarty, M. M. T. & Keller, G. (2004) The risks and benefits of teaching purely functional programming in first year. J. Funct.Program. 14 (1), 113123.CrossRefGoogle Scholar
Chambers, C., Chen, S., Le, D. & Scaffidi, C. (2012) The function, and dysfunction, of information sources in learning functional programming. J. Comput. Sci. Colleges 28 (1), 220226.Google Scholar
Clack, C. & Myers, C. (1995) The Dys-functional student. In Functional Programming Languages in Education, Hartel, P. & Plasmeijer, R. (eds), Lecture Notes in Computer Science, vol. 1022. Berlin/Heidelberg: Springer, pp. 289309.CrossRefGoogle Scholar
Damas, L. & Milner, R. (1982) Principal type-schemes for functional programs. In Proceedings of the 9th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages. Albuquerque, New Mexico, USA: ACM Press, ISBN 0-89791-065-6, pp. 207212.Google Scholar
Denny, P., Luxton-Reilly, A. & Tempero, E. (2012) All syntax errors are not equal. In Proceedings of the 17th ACM Annual Conference on Innovation and Technology in Computer Science Education. Haifa, Israel: ACM, pp. 75–80.CrossRefGoogle Scholar
Farchi, E., Nir, Y. & Ur, S. (2003) Concurrent bug patterns and how to test them. In Proceedings of Parallel and Distributed Processing Symposium, International, Nice, France, 2003. IEEE, p. 7.Google Scholar
Felleisen, M., Findler, R. B., Flatt, M. & Krishnamurthi, S. (2001) How to Design Programs. Cambridge: MIT Press.Google Scholar
Felleisen, M., Findler, R. B., Flatt, M. & Krishnamurthi, S. (2004) The structure and interpretation of the computer science curriculum. J. Funct. Program. 14 (4), 365378.CrossRefGoogle Scholar
Fenwick, J. B. Jr, Norris, C., Barry, F. E., Rountree, J., Spicer, C. J. & Cheek, S. D. (2009) Another look at the behaviors of novice programmers. ACM SIGCSE Bull. 41 (1), 296300.CrossRefGoogle Scholar
Findler, R. B., Clements, J., Flanagan, C., Flatt, M., Krishnamurthi, S., Steckler, P. & Felleisen, M. (2002) Drscheme: A programming environment for scheme. J. Funct. Program. 12 (02), 159182.CrossRefGoogle Scholar
Garrison, D. R. & Kanuka, H. (2004) Blended learning: Uncovering its transformative potential in higher education. Internet Higher Educ. 7 (2), 95105.CrossRefGoogle Scholar
Haberman, B. & Averbuch, H. (2002) The case of base cases: Why are they so difficult to recognize? student difficulties with recursion. In ACM SIGCSE Bulletin, vol. 34. ACM, pp. 84–88.CrossRefGoogle Scholar
Hage, J. & Keeken, P. (2006) Mining for Helium. Technical report UU-CS.Google Scholar
Hage, J. & Heeren, B. (2007) Heuristics for type error discovery and recovery. In Implementation and Application of Functional Languages, Springer, pp. 199216.CrossRefGoogle Scholar
Hall, C. V., Hammond, K., Peyton Jones, S. & Wadler, P. (1996) Type classes in Haskell. ACM Trans. Program. Lang. Syst. (TOPLAS) 18 (2), 109138.CrossRefGoogle Scholar
Heeren, B. J. (2005) Top Quality Type Error Messages, 2005/9/20, IPA Dissertation Series, Utrecht University.Google Scholar
Heeren, B., Leijen, D. & van IJzendoorn, A. (2003) Helium, for learning Haskell. In Proceedings of the 2003 ACM SIGPLAN Workshop on Haskell. Uppsala, Sweden: ACM, pp. 62–71.CrossRefGoogle Scholar
Hutton, G. (1999) A tutorial on the universality and expressiveness of fold. J. Funct. Program. 9 (4), 355372.CrossRefGoogle Scholar
Isomöttönen, V. & Tirronen, V. (2013) Teaching programming by emphasizing self-direction: How did students react to active role required of them? Trans.Comput. Educ. 13 (2), 6:16:21.CrossRefGoogle Scholar
Jadud, M. C. (2005) A first look at novice compilation behaviour using BlueJ. Comput. Sci. Educ. 15 (1), 2540.CrossRefGoogle Scholar
Joosten, S., Berg, K. & Hoeven, G. V. D. (1993) Teaching functional programming to first-year students. J. Funct. Program. 3 (1), 4965.CrossRefGoogle Scholar
Kahney, H. (1983) What do novice programmers know about recursion. In Proceedings of the SIGCHI Conference on Human Factors in Computing Systems. Boston, MA, USA: ACM, pp. 235–239.CrossRefGoogle Scholar
Keravnou, E. (1995) Introducing computer science undergraduates to principles of programming through a functional language. In Proceedings of the 1st International Symposium on Functional Programming Languages in Education. (FPLE '95), LNCS 1022, Nijmegen, The Netherlands: Springer-Verlag, ISBN-13: 978-3540606758, pp. 15–34.CrossRefGoogle Scholar
Kinnunen, P. & Malmi, L. (2006) Why students drop out CS1 course? In Proceedings of the 2nd International Workshop on Computing Education Research. University of Kent, Canterbury, UK. ICER '06. New York, USA: ACM, pp. 97–108.Google Scholar
Lahtinen, E., Ala-Mutka, K. & Järvinen, H. M. (2005) A study of the difficulties of novice programmers. SIGCSE Bull. 37 (3), 1418.CrossRefGoogle Scholar
Leblanc, R. J. & Fischer, C. N. (1982) A case study of run-time errors in Pascal programs. Softw.: Pract. Exper. 12 (9), 825834.Google Scholar
Lerner, B. S., Flower, M., Grossman, D. & Chambers, C. (2007) Searching for type-error messages. In ACM SIGPLAN Notices, vol. 42. ACM, pp. 425–434.CrossRefGoogle Scholar
Lewandowski, G. (2003) Using process journals to gain qualitative understanding of beginning programmers. J. Comput. Sci. Colleges 19 (1), 299310.Google Scholar
Lu, S., Park, S., Seo, E. & Zhou, Y. (2008) Learning from mistakes: A comprehensive study on real world concurrency bug characteristics. In ACM SIGPLAN Notices, vol. 43. ACM, pp. 329–339.CrossRefGoogle Scholar
Ma, L., Ferguson, J., Roper, M. & Wood, M. (2011) Investigating and improving the models of programming concepts held by novice programmers. Comput. Sci. Educ. 21 (1), 5780.CrossRefGoogle Scholar
Marceau, G., Fisler, K. & Krishnamurthi, S. (2011a) Measuring the effectiveness of error messages designed for novice programmers. In Proceedings of the 42nd ACM Technical Symposium on Computer Science Education. ACM, pp. 499–504.CrossRefGoogle Scholar
Marceau, G., Fisler, K. & Krishnamurthi, S. (2011b) Mind your language: On novices' interactions with error messages. In Proceedings of the 10th SIGPLAN. Tallinn, Estonia September 26–28, 2005, Symposium on New Ideas, New Paradigms, and Reflections on Programming and Software. ACM, pp. 3–18.CrossRefGoogle Scholar
McBride, C. & Paterson, R. (2008) Functional pearl: Applicative programming with effects. J. Funct. Program. 18 (1), 113.CrossRefGoogle Scholar
Morazán, M. T. (2011) Functional video games in the CS1 classroom. In Trends in Functional Programming, May 16–18, 2011, Madrid, Spain: Springer, pp. 166–183.CrossRefGoogle Scholar
Morazán, M. T. (2012) Functional video games in CS1 II. In Trends in Functional Programming, Springer, University of St Andrews, Scotland, UK, pp. 146162.CrossRefGoogle Scholar
Pane, J. F., Ratanamahatana, C. A. & Myers, B. A. (2001) Studying the language and structure in non-programmers' solutions to programming problems. Int. J. Human-Comput. Stud. 54 (2), 237264.CrossRefGoogle Scholar
Pea, R. D. (1986) Language-independent conceptual “bugs" in novice programming. J. Educ. Comput. Res. 2 (1), 2536.CrossRefGoogle Scholar
Perkins, D. N. & Martin, F. (1986) Fragile knowledge and neglected strategies in novice programmers. In Proceedings of 1st Workshop on Empirical Studies of Programmers on Empirical Studies of Programmers, Washington, DC, USA, pp. 213–229.Google Scholar
Ruehr, F. (2008) Tips on teaching types and functions. In Proceedings of the 2008 International Workshop on Functional and Declarative Programming in Education, September 21, 2008, Victoria, British Columbia, Canada: ACM, pp. 79–90.CrossRefGoogle Scholar
Segal, J. (1994) Empirical studies of functional programming learners evaluating recursive functions. Instr. Sci. 22 (5), 385411.CrossRefGoogle Scholar
Soloway, E. & Ehrlich, K. (1984) Empirical studies of programming knowledge. IEEE Trans. Softw. Eng. 595–609.CrossRefGoogle Scholar
Soloway, E., Ehrlich, K. & Bonar, J. (1982) Tapping into tacit programming knowledge. Proceedings of the 1982 Conference on Human Factors in Computing Systems. Gaithersburg, USA: ACM, pp. 52–57.CrossRefGoogle Scholar
Someren, M. W. (1990) What's wrong? Understanding beginners' problems with Prolog. Instr. Sci. 19 (4), 257282. 10.1007/BF00116441.CrossRefGoogle Scholar
Spohrer, J. G. & Soloway, E. (1986) Analyzing the high frequency bugs in novice programs. In Papers Presented at the 1st Workshop on Empirical Studies of Programmers on Empirical Studies of Programmers. Washington, DC, USA: Norwood, NJ, USA: Ablex Publishing Corp, pp. 230–251.Google Scholar
Stefik, A. & Siebert, S. (2013) An empirical investigation into programming language syntax. ACM Trans. Comput. Educ. (TOCE) 13 (4), 19.Google Scholar
Thompson, S. & Hill, S. (1995) Functional programming through the curriculum. In Functional Programming Languages in Education, FPLE LNCS 1022, Hartel, P. H. & Plasmeijer, M. J. (eds), Nijmegen, The Netherlands: Springer-Verlag, pp. 85102.CrossRefGoogle Scholar
Tinto, V. (1997) Classrooms as communities: Exploring the educational character of student persistence. J. Higher Educ. 68 (6), 599623.Google Scholar
Tirronen, V. & Isomöttönen, V. (In Press) Teaching types with a cognitively effective worked example format. J. Funct. Program.Google Scholar
Ulloa, M. (1980) Teaching and learning computer programming: A survey of student problems, teaching methods, and automated instructional tools. SIGCSE Bull. 12 (2), 4864.CrossRefGoogle Scholar
Vujoşevic-Janicic, M. & Toşic, D. (2008) The role of programming paradigms in the first programming courses. Teach. Math. XI (2), 6383.Google Scholar
Submit a response

Discussions

No Discussions have been published for this article.