A Visual Approach to Understand Parsing Algorithms through Python and Manim
P Akhilesh, Kandati Krishna, S Karthick Bharadwaj, Dwarapu Subham, Meena Belwal · 2024
Even with the growth of computer science and availability of new areas of specialization, the problem of building compilers continues to be a core subject and offered at many universities around the world. This area is not easy to teach and explore due to the number and specificity of the algorithms and ideas offered. The educational software systems are a critical component in the engineering education, as they enhance learning processes, since theoretical concepts and ideas are presented in a tangible form. So in this work a simple tool is developed, in Python that demonstrates the parsing processes of LL(1), LR(0),,LR(1), and LALR As the tool needs to generate a large and high quality visualizations such as syntax trees and step-by-step parsing animations, it is based on the Manim animation engine. The use of this tool for different grammars and input strings aids in learning the parsing algorithms while debugging and developing grammars can be made easier with the help of visualizations.