2. 已知文法G[S]: S→TB T→Ba| B→Db|eT| D→d|
时间: 2024-01-05 11:20:38 浏览: 203
根据提供的文法G[S],以下是对应的推导和短语的示例:
1. 对于句子(a,(a,a))的最左推导:
```
S => TB => BaB => aBaB => a(T)BaB => a(S)BaB => a(a)BaB => a(a,(T))Ba => a(a,(S))BaB => a,(a))BaB => a(a,(a))B => a(a,(a,a))
``2. 对于句型((T,S),a)的短语:
直接短语:((T,S),a)
句柄:(T,S)
阅读全文