编译原理(陈火旺第三版)练习答案(18)
发布时间:2021-06-07
发布时间:2021-06-07
编译原理(陈火旺第三版)练习答案
第七章
P217-1
a*(-b+c) 后缀式:ab-c+* a+b*(c+d/e) 后缀式:abcde/+*+ -a+b*(-c+d) 后缀式:a-bc-d+*+
not A or not(C or not D) 后缀式:A not C D not or not or (A and B)or(not C or D) 后缀式:A B and C not D or or
(A or B)and(C or not D and E)后缀式: A B or C D not E and or and if (x + y)*z = 0 then (a+b)↑c else a↑b↑c 后缀式:xy+z*0= ab+c↑ abc↑↑ if-then-else P217-3
-(a+b)*(c+d)-(a+b+c) 三元式: (1)+,a,b (2)-,(1),- (3)+,c,d (4)*,(2),(3) (5)+,a,b (6)+,(5),c (7)-,(4),(6) 间接三元式: 三元式表: (1)+,a,b (2)-,(1),- (3)+,c,d (4)*,(2),(3) (5)+,(1),c (6)-,(4),(5) 间接码表:(1),(2),(3),(4),(1),(5),(6) 四元式序列:
(1)+,a,b,T1 (2)-,T1,-,T2 (3)+,c,d,T3 (4)*,T2,T3,T4 (5)+,a,b,T5 (6)+,T5,c,T6 (7)-,T4,T6,T7