Less Talk, More Code: Practice-Based Instruction Improves Programming Skill Acquisition

Read full text
Authors: Gillian Gold, Jacob Tjaden, Paulo F. Carvalho
Cited by: 1

Abstract

Introductory computer science education often emphasizes watching experts write and explain code. We investigate whether practice-based instruction improves programming skills relative to traditional lectures and which features of practice make it effective. In this preregistered experiment (N = 250), we compared three approaches for an introductory programming lesson: watching a video, code tracing visualizations, and writing code with immediate, AI-generated feedback. Participants who engaged in practice-based instruction performed significantly better than those who watched the video on a novel code-generation test, with the highest performance among learners who practiced writing code. Practice-based instruction also resulted in reduced distraction and increased interest. Whereas video and code tracing conditions led to overconfidence about programming abilities, code writing led to underconfident self-assessments. These findings suggest that active practice, particularly generative practice with feedback, supports learning with advantages in cognitive processing, metacognition, and interest in programming.

Fields of Study & Subjects

Teaching and Learning Programming Visual and Cognitive Learning Processes Software Engineering Research

Publication details

Publisher
Center for Open Science
Publication date
12 February 2026
Document type
Preprint