Programming Education Using a Functional Programming Language
Yuri Kim, Korea University (Korea, Republic of)
Seoyeon Oh, Korea University (Korea, Republic of)
Soyeon Jeong, Korea University (Korea, Republic of)
Seongbin Park, Korea University, Seoul, Korea (Korea, Republic of)
Abstract
humanities, the demand for effective introductory programming courses has surged [1]. The right language can significantly influence a student's initial experience with coding, shaping their understanding, engagement, and overall success in learning programming concepts [2]. Programming languages often come with a variety of syntactic and semantic complexities that can pose significant challenges to beginners. These hurdles can lead to frustration and disengagement, especially for those without a strong technical background. Therefore, selecting an appropriate programming language that simplifies these complexities is crucial in fostering a positive and productive learning experience. The ideal programming language for novices should allow beginners to focus on understanding fundamental programming concepts such as variables, control structures, data types, and problem-solving strategies without being overwhelmed by the language's intricacies. The Clean programming language, in particular, offers several advantages, including a mathematical function-inspired syntax that provides a more intuitive coding experience [3]. This allows beginners to focus on logic and algorithm structure without being distracted by complex syntax rules [4]. Features such as immutability, a robust type system, higher-order functions, polymorphism, and concurrency contribute to code simplicity, reusability, and enhanced problem-solving capabilities [5]. Clean’s immutability reduces errors and facilitates reasoning about code, while its advanced type system and higher-order functions promote flexible and reusable code solutions. By comparing Clean with traditional languages like C, we evaluate its potential to enhance comprehension, reduce cognitive load, and improve overall student engagement and success. A comparative analysis was conducted between Clean and the C programming language, focusing on basic programming tasks such as sequencing, conditional statements, iterations, and termination. The assessment covered elements like types, variables, operators, methods, conditionals, loops, arrays, objects, classes, and file input/output operations. Our analysis shows that C code, on average, required approximately six times more lines and four times more words than Clean code, highlighting Clean's ability to produce concise and readable code. Our findings could provide valuable insights into the benefits of adopting Clean programming languages in introductory courses, ultimately contributing to more effective and inclusive programming education. High-level abstractions in Clean, such as list comprehensions, enable efficient and expressive solutions, reducing the cognitive load on beginners and easing their learning process. Integrating Clean into introductory programming courses can create a more beginner-friendly learning environment, enhancing comprehension of programming fundamentals and fostering problem-solving skills. For future work, we will continue to investigate Clean's effectiveness by conducting a substantial user study to assess its actual impact on learning, comparing it with other programming languages, and providing deeper insights into the benefits of employing functional programming languages in introductory programming education.