WebOct 28, 2013 · 1 L = { w w is of even length and begins with 01 } Ans: 01 ( (0 + 1) (0 + 1))* Explanation: 01 itself of even length to, we can suffix any even length string consist of 0 s and 1 s. L = { w the numbers of 1's in w is multiple of 3 } Ans: (0*10*10*10*)* WebApr 24, 2010 · Let L= { w in (0+1)* w has even number of 1s}, i.e. L is the set of all bit strings with even number of 1s. Which one of the regular expressions below represents L? …
Automata Theory Set 6 - GeeksforGeeks
WebL = {w w contains more 1s than 0s} Idea: this is similar to the language where the number of 0s is equal to the number of 1s, except we must ensure that we generate at least one 1, and we must allow an arbitrary number of 1s to be generated anywhere in the derivation. The following grammar accomplishes this task: S → S11S1 S1 → 0S11 1S10 ... Web(iv) If there exist languages L1 and L2 such that L(G) = L1 ∪ L2, then L1 and L2 must both be context free. (v) The language (L(G))R is context free. ... there is an odd number of a's and an even number of b's}. Show a pda that accepts L1 ∩ R1. Solutions 1. (a) L = ancbn. We can easily do this one by building a CFG for L. blue waters st lucia contact
automata - DFA that will accepts the string having odd number of 1
WebL = {w w contains more 1s than 0s} Idea: this is similar to the language where the number of 0s is equal to the number of 1s, except we must ensure that we generate at least one 1, … Webq0: fwjwhas an even length and all its odd positions are 0’s g q1: fwjwhas an odd length and all its odd positions are 0’sg q2: fwjwhas a 1 at some odd position g (b) (6 points) fwjjwjis divisible by 3 or it ends in 00g Solutions: we use the auxiliary function #(w) to refer to the number (in base 10) that is represented by the binary string w. Web0;w) 2F= fq 2gi whas an odd number of 0s and an odd number of 1s. Base Case: When w = , w has an even number of 0s and an even number of 1s and ^ (q 0; ) = q 0 so the observation holds vaccuously. Induction Step w= 0u: The parity of the number of 1s in uand wis the same, and the parity of the number of 0s is opposite. And ^(q 0;w) = ^ ( (q 0;0 ... blue waters st lucia contact number