1 / 7

右圖之 finite automata 可以用下列那一個正規表示式來描述? (A)(lO)* (B)l0*1*0 (C)1(01)*O (D)(01)*01 。

下列四組文法中,何者是 ambiguous ? (A)<S> ::= A | B (B)<S> ::= M <S> | H I <S> | R (C)<S> :: = <S> + <S> | a (D)<S> ::= 0 <S> 1 | 2. 右圖之 finite automata 可以用下列那一個正規表示式來描述? (A)(lO)* (B)l0*1*0 (C)1(01)*O (D)(01)*01 。.

misha
Download Presentation

右圖之 finite automata 可以用下列那一個正規表示式來描述? (A)(lO)* (B)l0*1*0 (C)1(01)*O (D)(01)*01 。

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. 下列四組文法中,何者是ambiguous?(A)<S> ::= A | B (B)<S> ::= M <S> | H I <S> | R (C)<S> :: = <S> + <S> | a (D)<S> ::= 0 <S> 1 | 2

  2. 右圖之finite automata可以用下列那一個正規表示式來描述?(A)(lO)* (B)l0*1*0 (C)1(01)*O (D)(01)*01。

  3. 8. 設有一文法(grammar)設定如下:<S> ::= a <S> c <B> | <A> | b<A> ::= c <A> | c<B> ::= d | <A>試選出下列何者不合文法。(A)abcd (B)acccbcd (C)aabcccc (D)accc

  4. 11. 下列的文法(grammar)可產生何字串(string)?(A)abab (B)abbaab (C)abbbaa (D)aababb。S→aBB→aBB|b

  5. 12. 下列的文法可接受的字串集合可以用那一個正規表示式(Regular expression)來描述?(A)yy*x+xy+y (B)yy*x+xy+yy (C)y*x+xy+yy (D)y*x+x*y+yy。S→Ax | ByA→y | AyB→x | y

  6. 15. 下面的文法無法接受那一個字串(string)?(A)abab (B)aabb (C)aaabbb (D)aababb。N={B,Σ}, T={a,b}P={Σ→aBB→aBBB→b}

  7. 13. 下面的文法可以接受那一個字串(string)?(A)abbc (B)ababbc (C)abaacc (D)abbacc。S → aBcB → bDb | bDD → a | ab

More Related