Code Cleanup 'var' settings
- Replace direction = Can change explicit type to 'var'
- 'foreach' iterator declaration type = Always use 'var'