Grammar Workbench

CS 432 — Eliminating Left Recursion · Left Factoring · FIRST / FOLLOW / FIRST+
Generated with the assistance of Claude Code (Opus 5)
One rule per line, symbols separated by spaces: E -> E + T | T. A symbol is a non-terminal iff it appears on some left-hand side. Empty right-hand side (or eps / ε) is ε. A trailing . is allowed, so Grammophone-style files paste in directly.
left recursion: — common prefixes: — LL(1): — left-recursive common prefix changed this step

Transformation Workbench

Click a highlighted problem to rewrite it — or let the tool apply every rewrite and step through the result

Load a grammar to begin
—

FIRST / FOLLOW / FIRST+

Recomputed for the grammar shown at left; conflicting rule pairs are flagged

Load a grammar to begin

Parse Trees — Before and After

The same string under the grammar as loaded and under the grammar as transformed

Original grammar

—

Current grammar

—