iterate through files