add minLendth method