C0VM.ts: C0 Visualizer on the cloud
What is C0 Language
The programming language C0 is a carefully crafted subset of the C aimed at teaching introductory algorithms and imperative programming. It is used in 15-122 Principles of Imperative Programming and 15-411 Compiler Design by more than 600 students each semester.
About This Project
This project is my project for Summer Undergraduate Research Fellowship (SURF) in CMU. More importantly, it's an attempt to improve students' 15-122 learning experience.
By employing various visualization and front-end technology, we make it possible to execute and visualize C0 Language on any device with modern browser. This project also allows instructors of 15-122 to embed runnable code exerciese in Learning Material System (LMS) like Canvas or Diderot thus creating a more interactive learning environment.
Live Demo
Try copy the following C0 code segment into the Code Editor then hit Compile & Run to see the result!
#use <conio>
int main() {
int*[] A = alloc_array(int*, 4);
A[1] = alloc(int);
*A[1] = 2;
printf("The value @ A[1] is a pointer pointing to %d", *A[1]);
return 0;
}
You can also set breakpoint on Line 8 by clicking on the left of line number. A red dot 🔴 will appear if the breakpoint is set successfully.
Main Features