[Overview] [Previous] [Next]

Acceptor for Ada identifiers

In Ada, an identifier consists of a letter followed by any number of letters, digits, and underlines. However, the identifier may not end in an underline or have two underlines in a row.

Here is an automaton to recognize Ada identifiers.

picture of automaton

M = (Q, sigma, delta, q0, F), where



Copyright 1996 by David Matuszek
Last modified Jan 29, 1996