In this course, you'll learn how to write cleaner, more maintainable code by identifying and addressing common code smells. You'll gain essential skills to enhance your software design abilities and create more efficient, scalable applications. By the end of the course, you'll be equipped to refactor and restructure problematic code into something more robust and readable.



Writing Clean Code: 20 Code Smells & How to Avoid Them

Dozent: Packt - Course Instructors
Bei enthalten
Empfohlene Erfahrung
Was Sie lernen werden
Master strategies for recognizing and refactoring common code smells that affect code readability and scalability
Understand the SOLID principles and how they improve software design and maintainability
Learn best practices for handling complex data structures, eliminating redundancy, and reducing technical debt
Gain the skills to simplify and streamline your codebase, making it more intuitive, flexible, and easier to maintain
Kompetenzen, die Sie erwerben
- Kategorie: Maintainability
- Kategorie: Software Design
- Kategorie: Programming Principles
- Kategorie: Debugging
- Kategorie: Object Oriented Design
- Kategorie: Software Design Patterns
- Kategorie: Code Review
- Kategorie: Scalability
- Kategorie: Software Architecture
Wichtige Details

Zu Ihrem LinkedIn-Profil hinzufügen
Mai 2025
23 Aufgaben
Erfahren Sie, wie Mitarbeiter führender Unternehmen gefragte Kompetenzen erwerben.

In diesem Kurs gibt es 24 Module
In this module, we will introduce the course and outline its goals. You will learn how identifying and removing code smells can drastically improve the quality and maintainability of your codebase, laying the groundwork for better software design practices.
Das ist alles enthalten
1 Video1 Lektüre
In this module, we will dive into essential software design principles, focusing on the SOLID principles. You'll explore how these principles can be applied to create cleaner, more maintainable, and scalable software architecture. We’ll also cover techniques for structuring modules effectively to improve code quality.
Das ist alles enthalten
7 Videos1 Aufgabe
In this module, we will guide you on how to read and comprehend large codebases effectively. You’ll learn techniques for navigating code efficiently and identifying areas where code smells can be improved or refactored for better clarity and maintainability.
Das ist alles enthalten
1 Video1 Aufgabe
In this module, we will introduce the repeated switch code smell and discuss its negative impact on code readability and maintainability. You will learn how to recognize and refactor repeated switch statements for cleaner, more maintainable code.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will explore the primitive obsession code smell, focusing on how overusing primitive data types can complicate your code. You will learn how to replace these with domain-specific objects, improving abstraction and readability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will address inefficient loop structures, one of the most common code smells, and discuss their impact on both performance and readability. We’ll provide best practices for refactoring loops to make them more efficient and easier to understand.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will cover the long parameter list code smell and how excessive parameters can complicate function signatures. You will learn strategies for simplifying these lists, such as using objects or default values to enhance readability and maintainability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will address the knowledge duplication code smell, explaining how repeated logic across the codebase can lead to inconsistencies and higher maintenance costs. You will learn techniques for refactoring and removing redundancies to improve the maintainability of your software.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will explore how uninformative comments can clutter your code and reduce clarity. You will learn how to write useful, concise comments and improve code readability by eliminating redundancy.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will dive into the shotgun surgery code smell, where changes in one part of the system require modifications across multiple classes. You will learn strategies for refactoring to reduce the complexity of these scattered changes and improve maintainability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will discuss the problem of alternative classes with inconsistent interfaces, which can lead to confusion and usability issues. You’ll learn how to refactor classes to unify interfaces and improve code consistency.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will explore the refused bequest code smell, which occurs when a subclass inherits functionality that it does not use. You’ll learn how to refactor your code to reduce misuse of inheritance and prefer composition to improve flexibility and maintainability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will address the data clumps code smell, where related data is grouped together inappropriately. You will learn how to refactor these data structures to improve organization and encapsulation for better maintainability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will examine the middle-man code smell, where unnecessary classes add complexity by simply delegating functionality. You’ll learn how to refactor your code by removing unnecessary abstraction layers to simplify your codebase.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will explore mutable data and how uncontrolled changes to state can lead to bugs and inconsistencies. You’ll learn how to refactor your code to manage data immutability effectively for better reliability and predictability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will address the feature envy code smell, where methods tend to focus too heavily on data from another class. You’ll learn how to refactor your code to improve object boundaries and move behavior to the class where it logically belongs.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will explore the divergent change code smell, where a module requires frequent modifications for unrelated reasons. You’ll learn how to refactor your code to minimize the risk of frequent changes causing instability or regressions.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will explore the issue of large interfaces and how they can make code difficult to maintain and extend. You’ll learn how to refactor large interfaces into smaller, more manageable ones that are easier to maintain and scale.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will address the multitasker code smell, where classes or methods take on too many responsibilities. You’ll learn how to apply the Single Responsibility Principle to refactor your code and improve its clarity and maintainability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will focus on the importance of clear, intuitive naming conventions. You will learn how unclear names can cause confusion and how to adopt best practices for naming variables, functions, and classes for improved readability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will discuss speculative generality and how over-engineering can make code unnecessarily complex. You’ll learn how to simplify code by removing premature abstractions and focusing on current requirements.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will explore the unnecessary exceptions code smell, where the excessive use of exceptions makes error handling more complicated than needed. You will learn how to simplify exception handling for clearer and more robust code.
Das ist alles enthalten
3 Videos1 Aufgabe
In this module, we will discuss the shallow module code smell, where modules contain little functionality relative to their complexity. You will learn how to refactor these modules to provide more meaningful functionality and enhance reusability.
Das ist alles enthalten
3 Videos1 Aufgabe
In this final module, we will summarize the key takeaways from the course, reinforce the importance of clean code practices, and offer guidance on how to continue improving your software design skills for better maintainability and scalability.
Das ist alles enthalten
1 Video1 Aufgabe
Erwerben Sie ein Karrierezertifikat.
Fügen Sie dieses Zeugnis Ihrem LinkedIn-Profil, Lebenslauf oder CV hinzu. Teilen Sie sie in Social Media und in Ihrer Leistungsbeurteilung.
Dozent

von
Warum entscheiden sich Menschen für Coursera für ihre Karriere?





Neue Karrieremöglichkeiten mit Coursera Plus
Unbegrenzter Zugang zu 10,000+ Weltklasse-Kursen, praktischen Projekten und berufsqualifizierenden Zertifikatsprogrammen - alles in Ihrem Abonnement enthalten
Bringen Sie Ihre Karriere mit einem Online-Abschluss voran.
Erwerben Sie einen Abschluss von erstklassigen Universitäten – 100 % online
Schließen Sie sich mehr als 3.400 Unternehmen in aller Welt an, die sich für Coursera for Business entschieden haben.
Schulen Sie Ihre Mitarbeiter*innen, um sich in der digitalen Wirtschaft zu behaupten.
Häufig gestellte Fragen
Yes, you can preview the first video and view the syllabus before you enroll. You must purchase the course to access content not included in the preview.
If you decide to enroll in the course before the session start date, you will have access to all of the lecture videos and readings for the course. You’ll be able to submit assignments once the session starts.
Once you enroll and your session begins, you will have access to all videos and other resources, including reading items and the course discussion forum. You’ll be able to view and submit practice assessments, and complete required graded assignments to earn a grade and a Course Certificate.
Weitere Fragen
Finanzielle Unterstützung verfügbar,