by Paul-Craft · 2y ago · 0 comments
> m = re.match(r"(?P<num>[0-9]+)|(?P<op>[-+*/()<>=])|(?P<ws>\s+)|(?P<kw>begin|end\.|end|if|then|while|do|var|!|\?|call|procedure)|(?P<id>[a-zA-Z]+)|(?P<semi>;)|(?P<asgn>:=)|(?P<comma>,)", code)
can be called simple. APL's is similar but less complex.
Notably, however, the BASIC and LISP interpreters are* delightfully simple throughout.