Syntax-Baum
Version: 0.9.1
Simple Programming Language (in Backus-Naur-Form)
::= < statement list >
< statement list > ::= < statement > | < statement list > ; < statement >
< statement > ::= < input statement> | < output statement > | < assignment statement > | < conditional statement > | < definite loop > | < indefinite loop >
< input statement > ::= read < variable list >
< output statement > ::= write < variable list >
< variable list > ::= < variable > | < variable list > , < variable >
< assignment statement > ::= < variable > := < expression >
< conditional statement > ::= if < comparison > then < statement list > fi | if < comparison > then < statement list > else < statement list > fi
< definite loop > ::= to < expression > do < statement list > end
< indefinite loop > ::= while < comparison > do < statement list > end
< comparison > ::= < expression > < relation > < expression >
< expression > ::= < term > | < expression > < weak operator > < term >
< term > ::= < element > | < term > < strong operator > < element >
< element > ::= < constant > | < variable > | (< expression >)
< constant > ::= < digit > | < constant > < digit >
< variable > ::= < letter > | < variable >< letter > | < variable > < digit >
< relation > ::= = | =< | < | > | >= | <>
< weak operator > ::= + | -
< strong operator > ::= * | /
< digit > ::= 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
< letter > ::= a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | v | w | x | y | z