Remove useless symbols from S→AB|Ca, B→BC|AB, A→a, C→aB|b

December 4, 2026 · Team EasyExamNotes · 1 min read (est.) · 0 comments

Share on WhatsApp

← RGPV CS-501 Theory of Computation November 2023 Solved Paper

Question

Remove useless symbols from the CFG S→AB|Ca, B→BC|AB, A→a, C→aB|b.

Asked in: CS-501 | November 2023 | 2(a)

Answer

B is nonproductive: every production for B contains B. Delete B and all rules containing it. Remaining S→Ca, A→a, C→b. A is now unreachable from S; remove it. Final grammar S→Ca, C→b generates exactly ba.

← RGPV CS-501 Theory of Computation November 2023 Solved Paper

Discussion

Ask a question, share your thoughts or report an error.

Sign in to participate in the discussion.

Join the discussion