added more loops