title: Trace of parse for input string using parse table
body: <p>Our professor never got around to teaching us this material in class, and now we have homework on it. Google seems to be leading me in the right direction, but I want to make sure I get it right (of course).</p>
  
  <p>We were given the following grammar and asked to make a parse table based on it:</p>
  
  <pre><code>1.  S -&gt; ABe
  2.  A -&gt; dB
  3.  A -&gt; aS
  4.  A -&gt; c
  5.  B -&gt; AS
  6.  B -&gt; b
  </code></pre>
  
  <p>My parse table:</p>
  
  <pre><code>_| a | b | c | d | e | #
  S|ABe|   |ABe|ABe|   |
  A|aS |   | c |dB |   |
  B|AS | b |AS |AS |   |
  </code></pre>
  
  <p>Now we're instructed:</p>
  
  <blockquote>
    <p>"Using your parse table, give a trace of the parse for the input
    string dbbe.  Give the unused input string, stack, and output
    (sequence of rule numbers) at the beginning of each iteration."</p>
  </blockquote>
  
  <p>On my internet search, I was able to find this example:
  <a href="https://i.stack.imgur.com/wFGdd.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/wFGdd.png" alt="enter image description here"></a></p>
  
  <p>Source: <a href="http://what-when-how.com/compiler-writing/top-down-parsing-compiler-writing-part-1/" rel="nofollow noreferrer">http://what-when-how.com/compiler-writing/top-down-parsing-compiler-writing-part-1/</a></p>
  
  <p>It looks as if you go through each possibility given in the grammar until you match with the string.</p>
  
  <p>Here's what I came up with:</p>
  
  <p><a href="https://i.stack.imgur.com/BxSOu.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/BxSOu.png" alt="enter image description here"></a></p>
  
  <p>How's this? Am I understanding it right? I made this by only referencing the grammar; not my parse table..How would I use my parse table to make a trace?</p>
  
  <p>I'm still unsure what this means: </p>
  
  <blockquote>
    <p>Give the unused input string, stack, and output (sequence of rule
    numbers) at the beginning of each iteration</p>
  </blockquote>