Use  in foreach
Remove unused variable