Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
context-free_grammars [2011/10/24 09:28] vkuncak |
context-free_grammars [2015/04/21 17:32] (current) |
||
---|---|---|---|
Line 32: | Line 32: | ||
* at each step, we select a non-terminal N in our string $p$ and select a production with N as left-hand side, and replace non-terminal with the right-hand side, obtaining string $p'$ (this process is denoted $p \Rightarrow p'$) | * at each step, we select a non-terminal N in our string $p$ and select a production with N as left-hand side, and replace non-terminal with the right-hand side, obtaining string $p'$ (this process is denoted $p \Rightarrow p'$) | ||
- | $u \Rightarrow^{+} v$ means $v$ is obtained from $u$ by one or more $\Rightarrow$ steps\ | + | $u \Rightarrow^{+} v$ means $v$ is obtained from $u$ by one or more $\Rightarrow$ steps |
$u \Rightarrow^{*} v$ means $v$ is obtained from $u$ by zero or more $\Rightarrow$ steps | $u \Rightarrow^{*} v$ means $v$ is obtained from $u$ by zero or more $\Rightarrow$ steps | ||
- | \[ | + | \begin{equation*} |
L(G) = \{ w \mid w \in \Sigma^*, \ S \Rightarrow^* w \} | L(G) = \{ w \mid w \in \Sigma^*, \ S \Rightarrow^* w \} | ||
- | \] | + | \end{equation*} |
=== Shorthands for Writing Context-Free Grammars === | === Shorthands for Writing Context-Free Grammars === | ||
Line 123: | Line 123: | ||
* examples of [[http://www.elsewhere.org/pomo/|using grammars for text generation]] | * examples of [[http://www.elsewhere.org/pomo/|using grammars for text generation]] | ||
+ | * type "compiler construction" into http://www.essaygenerator.com | ||
+ | |||
+ | "How much responsibility lies with compiler construction? We can say that compiler construction deserves all of the attention it gets. It establishes order, provides financial security and it brings the best out in people." | ||
===== References ===== | ===== References ===== |