Ultimate Clean Code Masterclass for 2025

Ultimate Clean Code Masterclass for 2025

English | MP4 | AVC 1280×720 | AAC 44KHz 2ch | 165 lectures (13h 19m) | 4.38 GB

Write high-quality code no matter the language. Follow SOLID principles and avoid common code smells and antipatterns.

Welcome to the “Ultimate Clean Code Masterclass”, the only course you need to take the quality of your code to the next level!

I’m a Technical Lead with over 10 years of professional experience. I will help you on this journey every step of the way, no matter if you’re a beginner looking to form good habits or an experienced developer aiming to sharpen your skills.

Throughout the course, we’ll dive into the principles of clean code, focusing on essential topics like naming conventions, code formatting, and the design of functions and classes. You’ll learn how to write code that is easy to understand and modify. By the end of the course, you’ll have a solid grasp of how to keep your codebase clean and avoid common pitfalls that lead to technical debt.

SOLID principles are the foundation of well-designed code, and we will explore them in detail.

Refactoring is something we will practice all the time. You’ll see examples of code that violates clean coding principles and learn how to transform it into a clean, professional solution.

This course will help you become a more efficient developer. Clean code leads to fewer bugs, easier debugging, and faster implementation of new features.

Unit tests are an essential tool in every programmer’s toolkit. We will learn how to write clean tests, as well as how to design our code so it is testable.

By the end of the course, you’ll have the knowledge and confidence to write clean, elegant code that will stand the test of time. Whether you’re working on a small side project or collaborating on large enterprise-level applications, mastering clean code will take your development skills to the next level. Join me and start writing cleaner, smarter, and more professional code today!

This course is meant for programmers of any language. Examples will be provided in C#.

What you’ll learn

  • Write code of excellent quality
  • Understand the importance of clean code
  • Understand SOLID principles and learn to refactor the code so it complies with them
  • Create great design, so your code can be easily extended and modified
  • Avoid common code smells and antipatterns
  • Practice refactoring the existing code
Table of Contents

Introduction
1 Welcome! Basic information & how to get help
2 seconds about your instructor
3 seconds about this course
4 seconds about time optimization
5 Accessing the code
6 To my “Ultimate C# Masterclass” learners
7 Resources

The importance of clean code
8 Before we start essential vocabulary
9 The importance of clean code
10 Bad decisions related to code quality
11 Tech debt
12 Being professional
13 What is clean code
14 Good and bad code – comparison
15 Clean code and AI

Naming
16 The importance of meaningful names
17 Naming fundamentals
18 Following the convention
19 Why do we use bad names
20 Renaming. The Boy Scout rule
21 Dealing with problematic naming
22 Expressive names
23 Long and short names
24 The Principle of Least Surprise
25 Semantic correctness
26 Homonyms
27 Synonyms
28 Consistency
29 Matching plurality
30 The natural language we use in code
31 Imitating the spoken language
32 Bad names – meaningless words
33 Bad names – overspecific names
34 Bad names – Hungarian notation
35 Bad names – confusing names
36 Bad names – abbreviations
37 Reasonable abbreviations. Conventional names
38 Context
39 Refactoring case studies – introduction
40 Refactoring case study Naming

Functions
41 Functions fundamentals
42 Good signatures of methods
43 Number of parameters
44 Fewer parameters – splitting the method
45 Fewer parameters – bundling related parameters
46 Fewer parameters – avoiding boolean parameters
47 Fewer parameters – bad practices
48 Order of parameters
49 Ref and out parameters (C# specific topic)
50 Small methods
51 One method, one job
52 Achieving methods focused on one task only
53 Refactoring case study One method, one job
54 Levels of abstraction
55 Composing different levels of abstraction
56 Levels of abstraction within methods
57 Order of methods
58 Independence of methods
59 Pure functions
60 The benefits of pure functions
61 Refactoring case study Methods – introduction
62 Refactoring case study Methods – signature
63 Refactoring case study Methods – body

Code formatting
64 The importance of code formatting
65 Different formatting styles and the value of consistency
66 Code formatting tools
67 Indentation
68 Code blocks
69 Breaking the lines
70 Vertical formatting
71 Refactoring case study Code formatting – code
72 Refactoring case study Code formatting

SOLID principles
73 Classes fundamentals
74 Introduction to SOLID principles
75 S – Single Responsibility Principle – theory
76 S – Single Responsibility Principle – code & refactoring
77 S – Single Responsibility Principle – Recognizing single responsibility
78 S – Single Responsibility Principle – One reason to change
79 Abstract types
80 O – Open-closed Principle – theory
81 O – Open-closed Principle – code
82 O – Open-closed Principle – refactoring
83 O – Open-closed Principle – limitations – toggle mechanism
84 O – Open-closed Principle – limitations – can’t predict all the changes
85 O – Open-closed Principle – limitations – practicality
86 L – Liskov Substitution Principle – theory
87 L – Liskov Substitution Principle – violation of the interface
88 L – Liskov Substitution Principle – violation of the interface – refactoring
89 L – Liskov Substitution Principle – runtime type switching
90 L – Liskov Substitution Principle – runtime type switching – refactoring
91 L – Liskov Substitution Principle – condition strengthened for subtype
92 L – Liskov Substitution Principle – condition strengthened for subtype – refac
93 I – Interface Segregation Principle – theory
94 I – Interface Segregation Principle – code
95 I – Interface Segregation Principle – refactoring
96 I – Interface Segregation Principle – reasoning
97 D – Dependency Inversion Principle – theory
98 D – Dependency Inversion Principle – relationship with Dependency Injection
99 D – Dependency Inversion Principle – dynamic dependency creation
100 D – Dependency Inversion Principle – code & refactoring
101 Refactoring case study SOLID principles – code
102 Refactoring case study SOLID principles – part 1
103 Refactoring case study SOLID principles – part 2

Static methods
104 When to make methods static Private methods
105 The risk of making public methods static
106 When to make methods static Public methods
107 Obscuring the dependency graph
108 Obscuring the dependency graph – why is it bad
109 Transparent dependency graph

Classes – making them smaller
110 Benefits of small classes. God class antipattern
111 Not all large classes are bad
112 Making classes smaller – bad practices
113 Making classes smaller – good practices – names
114 Making classes smaller – good practices – data usage & dependencies
115 Making classes smaller – good practices – frequent changes in one area
116 Making classes smaller – good practices – multiple levels of abstraction
117 Can we have too many classes
118 Refactoring case study Making classes smaller – code
119 Refactoring case study Making classes smaller – part 1
120 Refactoring case study Making classes smaller – part 2
121 Refactoring case study Making classes smaller – part 3

Classes – design & formatting
122 Order of class members
123 One class, one file
124 Folder structure within projects
125 Consistency
126 Coupling
127 Refactoring the code to achieve loose coupling
128 Identifying and fixing tight coupling
129 Law of Demeter
130 Cohesion
131 DRY – Don’t Repeat Yourself – repeating business logic
132 DRY – Don’t Repeat Yourself – repeating code
133 DRY – Don’t Repeat Yourself – when it’s OK to repeat the code
134 Avoiding BDUF (Big Design Up Front). YAGNI
135 KISS (Keep It Simple, Stupid)
136 Refactoring case study Classes – design & formatting – code
137 Refactoring case study Classes – design & formatting – part 1
138 Refactoring case study Classes – design & formatting – part 2
139 Refactoring case study Classes – design & formatting – part 3

Classes – inheritance
140 Composition over inheritance
141 The issues of inheritance
142 Replacing inheritance with composition
143 The benefits of composition

Comments
144 Comments
145 The worst comments
146 The reasonable comments
147 Refactoring case study

Clean tests & testability
148 Unit tests fundamentals
149 Mocks fundamentals
150 The importance of unit tests
151 How unit testing affects code quality – safety net
152 How unit testing affects code quality – better design
153 How unit testing affects code quality – Test-Driven Development (TDD)
154 The importance of clean tests
155 Tests readability
156 Good practices for writing clean tests
157 Testability pitfalls – static methods
158 Testability pitfalls – breaking the Dependency Inversion Principle
159 Testability pitfalls – not using Dependency Injection
160 Testability pitfalls – constructor does real work
161 Keeping constructors simple
162 Refactoring case study Clean tests & testability – code
163 Refactoring case study Clean tests & testability – comments
164 Refactoring case study Clean tests & testability – tests

Bonus section
165 Bonus lecture

Homepage