Professional Documents
Culture Documents
Task 1
Provide the language L of strings defined over ∑= {0, 1, 2} for the strings belonging to the
following languages: [w means a string of that language – string first position is 1]
a) All strings having zeros in multiples of three, but always having 2 either followed or
behind but not both
b) All strings that do not start with double zero.
c) All strings starting with zero have no consecutive 1’s or 2’s in them.
d) L1 = {w | w contains an even number of 0’s and odd number of 1’s}
e) L2 = {w | Every odd position of w is a 0 and for even no rule to follow}
f) L3 = {w | w contains the substring 11 an odd number of times, but no overlapping to be
counted}.
Task 2