Code Smells: Identifying and Refactoring Troubled Code