美麗的世界

上帝創造了一個美麗的世界,讓我們用心的去愛這個世界吧!

Wednesday, March 09, 2005

程式語言的語法

1.基本的定義:字串定義,字串運算
2.文法要素:4要素N,T,P,S(Nonterminal,Terminal,Production,Start
3.文法分類:4類type 0,1,2,3
4.BNF文法 TYPE 2=>BNF context free grammar
5.剖析樹parse tree
6.模擬兩可的文法ambiguous grammar
7.dangling else 懸置else :if條件A then if 條件 B then exp1 else exp2
====>else 無法定與那一個if 結合
程式語言的控制結構 pascal: else 與最近的if 結合
(1)dangling else
(2)dangling reference
(3)dangling label reference

0 Comments:

Post a Comment

<< Home