The Gateway to Computer Science Excellence
0 votes
143 views

Let L be the language of all strings on [0,1] ending with 1.

Let X be the language generated by the grammar G.

$S \rightarrow 0S/1A/ \epsilon $

$A \rightarrow 1S/0A$

Then $L \cup X= $

  1. ∑*
  2. L
  3. X

Ans given : B. ∑*

They said that X is a language which contains all strings that do not end with 1. But is it so?

Can’t we generate 11 from the grammar?

Please verify.

in Theory of Computation by Boss (23.5k points)
edited by | 143 views
0

They said that L is a language which contains all strings that do not end with 1.

Not X

0

@Registered user 48

Yes sorry..will edit that :P

0
I thought the question itself was given like that and you interpreted it wrong :p
0

@Registered user 48

Oh it was right before only.. I suddenly got confused. See their solution..

They said that L(X) = not ending with 1. But 11 is a valid string.

Please log in or register to answer this question.

Related questions

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
50,737 questions
57,312 answers
198,343 comments
105,035 users