added two more whiles