定义:
M={Q, ∑, f, q0, F}
q = f(q, δ)
σ ∈ Σ
(q, q0, F) ∈ Q
算法:
Stack S ← (-1, -1);
i = 0;
T = q0;
while (T != -1 && i != -1)
{
  if (i == 0 && T is Accept)
  {
    call AcceptCallBack;
  }
  if (i < T.Children.Count)
  {
    S ← (T, i + 1);
    T = f(T, i);
    i = 0;
  }
  else
  {
    (T, i) ← S;
  }
}

 

posted on 2014-02-18 16:25  RexfieldVon  阅读(524)  评论(0编辑  收藏  举报