more practice with js loops