Build an FA separately, accepting each of the following languages

  • 1. An identifier of up to six characters, switched on and off with one alphanumeric character followed by zero to five alphanumeric characters.

  • 2. A string containing one or more pairs, each consisting of an open parenthesis and a close parenthesis

  • In Pascal, a comment consisting of an open curly brace {followed by zero or more characters from the alphabet ∑, followed by a close curly brace}.