switched to iterator as per comments