You can prove the equivalence of two regular expressions by constructing a minimal DFA for each expression and showing that the two automata are equivalent. Prove that 1* | (1*01*01*)* and 1*(1*01*01*)* are equivalent.
Construct a minimal DFA for 1|1(1|0)*1 and write a program based on the DFA to detect if an input string is a valid token of the language.
Write a scanner to detect if a given string is a valid financial quantity as defined by the following regular expression:
D -> 0..9
NZ -> 1..9
$(*)*(0 | NZ[D][D](,DDD)*)[.DD]