cloned the list before iterating