Visualizing Environments of Modern Scripting Languages

Kaian Cai, Martin Henz, Kok-Lim Low, Xing Ng, Jing Soh, Kyn-Han Tang, Kar Toh

2023

Abstract

A central learning objective of introductory programming courses is a thorough understanding of environments that arise when programs written in modern programming languages run. An awareness is arising in the CSEd community that a mental model based on a runtime stack does not do justice to languages that combine lexical scoping with first-class functions. As a result, debugging and visualization tools designed around a runtime stack are not suitable for this family of languages, which includes Python, JavaScript, Ruby, Lua, Java, and Scheme. As a suitable mental model for environments in these languages, the classical programming textbook “Structure and Interpretation of Computer Programs” (SICP) introduced the environment model of computation using diagrammatic graphics. The SICP authors Hal Abelson and Gerald Jay Sussman designed the environment model to represent the runtime data structures required for executing programs written in such languages while blending out all forms of control. In this paper, we describe a novel tool for automatically and interactively visualizing the execution environments of programs written in the targeted language family. After introducing the environment model in detail, we highlight the main challenges for its automatic and interactive visualization. We outline the architecture of the tool and its integration into a web-based environment for learning the structure and interpretation of computer programs and conclude with an analysis of the tool’s impact based on feedback from 69 course facilitators in Academic Year 2021/22.

Download


Paper Citation


in Harvard Style

Cai K., Henz M., Low K., Ng X., Soh J., Tang K. and Toh K. (2023). Visualizing Environments of Modern Scripting Languages. In Proceedings of the 15th International Conference on Computer Supported Education - Volume 1: CSEDU, ISBN 978-989-758-641-5, SciTePress, pages 146-153. DOI: 10.5220/0011766700003470


in Bibtex Style

@conference{csedu23,
author={Kaian Cai and Martin Henz and Kok-Lim Low and Xing Ng and Jing Soh and Kyn-Han Tang and Kar Toh},
title={Visualizing Environments of Modern Scripting Languages},
booktitle={Proceedings of the 15th International Conference on Computer Supported Education - Volume 1: CSEDU,},
year={2023},
pages={146-153},
publisher={SciTePress},
organization={INSTICC},
doi={10.5220/0011766700003470},
isbn={978-989-758-641-5},
}


in EndNote Style

TY - CONF

JO - Proceedings of the 15th International Conference on Computer Supported Education - Volume 1: CSEDU,
TI - Visualizing Environments of Modern Scripting Languages
SN - 978-989-758-641-5
AU - Cai K.
AU - Henz M.
AU - Low K.
AU - Ng X.
AU - Soh J.
AU - Tang K.
AU - Toh K.
PY - 2023
SP - 146
EP - 153
DO - 10.5220/0011766700003470
PB - SciTePress