in Compiler Design retagged by
352 views
0 votes
0 votes
X-->Ya|f

Y-->bY|d

Z-->cZ|e

FOLLOW(Z)???
in Compiler Design retagged by
by
352 views

3 Comments

follow(Z) = { } = phi
0
0
@joshi if z is starting symbol then it should be $ else its not reachable right?
0
0
yes.
0
0

1 Answer

0 votes
0 votes
First of all Z is unreachable variable...that is .....no production is able to reach upto Z....

now follow of Z (which is in R.H.S) is follow is Z (which is in L.H.S)...

but there is no occurence of Z in any production in RHS side ...

so here follow of Z is { }....PHI......

(actually we never get follow of any variable as PHI...but as variable is UNREACHABLE...we say it as PHI...)

1 comment

thnx
0
0