The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
0 votes
I am confused in the Concept of Handles in right sentential form and Viable Prefix. Can Please anybody explain these two concepts Briefly using Examples :)
asked in Compiler Design by Loyal (6.6k points) | 162 views

1 Answer

0 votes

A viable prefix of a sentential form φβt, where β denotes the handle, is any prefix of φβ. A viable prefix cannot contain symbols to the right of the handle.

(source: )


S → E#,

E → E + T | E − T | T,

T → id | (E)


S ⇒ E#E + T # ⇒ E + (E)# ⇒ E + (T)# ⇒ E + (id)#

(bold and underlined are the handles for that right sentential form)


all viable prefixes of the right sentential form E + (id)# :

E, E+, E + (, and E + (id

as ' id ' is the handle of this sentential form so we cant take any other symbol in its right( for viable prefix)



E + (id)# is a right sentential form

id is its handle and,

E, E+, E + (, and E + (id  are its Viable prefixes.

answered by (245 points)

Related questions

+2 votes
1 answer
asked Nov 12, 2016 in Compiler Design by KISHALAY DAS Active (4.9k points) | 1.1k views
+2 votes
1 answer
asked Dec 2, 2015 in Compiler Design by yes Active (1.2k points) | 845 views
+2 votes
1 answer
asked Jul 18, 2015 in Compiler Design by Suvam Chatterjee (437 points) | 827 views
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
49,540 questions
54,099 answers
71,006 users