Building a Simple Python Interpreter in 168 Lines
A detailed walkthrough of creating a basic programming language interpreter in Python, covering code blocks, error handling, comments, variables, and expressions within a compact codebase.

Slu4
10.3K views β’ Jan 7, 2022

About this video
I explain the inner workings of a computer language interpreter that features code blocks, error messages, comments, integer and string variables, math expressions, if-else, while-break, print, input, and subroutine calls. I build on the fantastic work by Jack W. Crenshaw. The interpreter only uses low-level Python.
"Let's Build a Compiler" by Jack W. Crenshaw:
https://compilers.iecc.com/crenshaw/
Minimal UART CPU System on GitHub:
https://github.com/slu4coder/Minimal-UART-CPU-System
https://github.com/slu4coder/Minimal-UART-CPU-System/tree/main/Min%20Language
Minimal User Manual and Reference:
https://docs.google.com/document/d/1c2ZHtLd1BBAwcBAjBZZJmCA3AXpbpv80dlAtsMYpuF4/edit?usp=sharing
"Let's Build a Compiler" by Jack W. Crenshaw:
https://compilers.iecc.com/crenshaw/
Minimal UART CPU System on GitHub:
https://github.com/slu4coder/Minimal-UART-CPU-System
https://github.com/slu4coder/Minimal-UART-CPU-System/tree/main/Min%20Language
Minimal User Manual and Reference:
https://docs.google.com/document/d/1c2ZHtLd1BBAwcBAjBZZJmCA3AXpbpv80dlAtsMYpuF4/edit?usp=sharing
Tags and Topics
Browse our collection to discover more content in these categories.
Video Information
Views
10.3K
Likes
381
Duration
17:19
Published
Jan 7, 2022
User Reviews
4.6
(2) Related Trending Topics
LIVE TRENDSRelated trending topics. Click any trend to explore more videos.
No specific trending topics match this video yet.
Explore All Trends