Match in length order, for faster run times