2025 ASEE Annual Conference & Exposition

BOARD # 201: Development of a Programming Environment to Bridge Students from Block-Based to Text-Based Programming (Work in Progress)

Presented at WIP Poster Session: Emerging Research and Practices in Pre-College Engineering Education

Many students’ first interaction with computer science is programming using a block-based programming environment like Scratch, a popular introductory block-based coding platform. Scratch works well for beginner programmers for several reasons, including that Scratch’s draggable code blocks prevent syntax or spelling errors and every code block is easily available so users aren’t required to memorize dozens of functions. Scratch also motivates users to create by giving users the ability to showcase creativity, art, visual storytelling, and music in their projects. Despite widespread adoption, students can have difficulty transitioning the skills they initially develop in block-based programming environments into text-based programming languages like Python.

Prior research (Kölling et al, 2015) has identified many reasons for why students experience difficulty during the transition from block-based to text-based programming, including memorization of commands, typing/spelling, and changing programming paradigms. Additionally, the complex and unfamiliar interfaces of some text-based coding environments lead many students to feel lost when first learning Python, even if they had significant Scratch experience.

Prior experience, skills, and familiarity is helpful for students who are asked to explore a difficult topic, and contribute to student self-confidence. This is especially important in computer science because syntax and runtime errors can be frustrating and students’ self-confidence gives them the resiliency to overcome these problems. Thus, new introductory text-based programming experiences can be built to leverage prior block-based experience. Rather than changing the syntax, vocabulary, and output modalities all at once on students, we believe a programming environment should primarily introduce students to the most fundamental shift between block-based and text-based programming: typing lines of code rather than dragging code blocks. Keep every other aspect of the students’ experience stable until they build confidence in creating programs by typing code.

This paper presents Patch, a Pythonic web-based introductory programming environment that bridges the gap between Scratch and Python. To maintain student familiarity, Patch’s layout is very similar to Scratch, with the only major difference being a Python text editor in place of Scratch’s block-based code editor. Furthermore, every Scratch block has a direct translation into Patch. Any Scratch project can be uploaded into Patch, where the code blocks will be automatically translated into text-based code. For example, the Scratch “Move 10 Steps” block is written in Patch as move(10), with the same result of making a character move 10 units across the screen. While Patch has custom functions for many Scratch blocks, Patch uses default Python variables, loops, if statements, functions, and more. When students eventually transition from Patch to Python, they’re already familiar with a majority of the core Python concepts and syntax.

Patch was piloted with 26 middle school students across two different week-long summer educational programs during the summer of 2023. Throughout these pilot programs, researchers took notes on student behavior, conducted informal interviews with program instructors after each day, and examined student artifacts. From this qualitative data, we found early signs that students were able to successfully transfer knowledge from Scratch into Patch and from Patch into Python, demonstrating the viability of Patch as an intermediate pathway for transitioning students from block-based to text-based programming. This work discusses the implications of our findings and proposes next steps for further understanding the effects of learning with the Patch platform, along with providing recommendations for updates and improvements to Patch.

Authors
  1. Elliot Benjamin Roe Georgia Institute of Technology
  2. Duncan Johnson Tufts Center for Engineering Education and Outreach [biography]
Note

The full paper will be available to logged in and registered conference attendees once the conference starts on June 22, 2025, and to all visitors after the conference ends on June 25, 2025

« View session

For those interested in:

  • Pre-College