See here for basic rules on problem.
Problem #6
Make an optimal machine that accepts sequences of integer digits 1-4 such that all 1s are at the beginning and all 4s are at the end. Also there has to be exactly one of either the 2 or the 3 with any number of the other in each sequence. There doesn't have to be any 1s or 4s.
You do not need a route for failed sequences.