in Theory of Computation edited by
274 views
0 votes
0 votes
If $A$ and $B$ are languages, define $A \diamond B = \{xy \mid x \in A\: \text{and}\: y \in B \;\text{and}  \mid x \mid = \mid y \mid \}$. Show that if $A$ and $B$ are regular languages, then $A \diamond B$ is a CFL.
in Theory of Computation edited by
by
274 views

1 comment

Clearly there is a comparison between x and y , so its a cfl.
0
0

1 Answer

0 votes
0 votes

Suppose,  A = { 0^n | n > 0 }    and

                 B = { 1^n | n > 0 }

     By def. of a and b having  any no of 0s and 1s repectively

 both are regular languages

BUT,   A ∘ B = { 0^n.1^n  | n >0 }

         which is a renowned  cfl .

same applies for →  B∘A

Related questions