Reorder the methods.
Determine if b is congruent to a mod n.