Abstract syntax tree
In computer science, an abstract syntax tree (AST), or just syntax tree, is a tree representation of the abstract syntactic structure of text (often source code) written in a formal language. Each node of the tree denotes a construct occurring in the text.
— Wikipedia
Abstract syntax trees are used in program analysis and program transformation systems. As example Euclidean algorithm is shown below.
To produce an AST need to use parser.
AST.excalidrawAn abstract syntax tree for the Euclidean algorithm