Question 1:
           a)   Determine which of the following sets have valid / invalid alphabets:
           Σ1 = {a, ab, b, d, ae}
             Σ2 = {a, ba, c, d}

        b)  Consider Σ = {ab, baa, c, db} to find the length of the string s=abbaaabdbbaa by tokenizing. Give its reverse Rev (s).

         Question 2:
          a)    Give the regular expression RE over Σ = {a, b} for the language of all words having b as a second letter. 

       b)   What will be the Finite Automata for above language?

Please show what you have so far as well as where you're confused, so we can help you to learn and complete the assignment.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.