Course Outline
Day 1
Introduction
Standardized and Effective Naming
- Package, file, class, variable, function, and method names must be meaningful and reflect their purpose.
- Names should be easily readable.
- Names should be searchable.
- Consider the namespace context: does it make logical sense?
Classes, Objects, and Data Structures
- Distinguish between objects that perform actions and structures that simply hold data.
- Understand when and why to use data structures.
- Understand when and why to use objects.
- Explore OOD (Object-Oriented Design) and abstraction.
- Discuss the role of getters and setters.
- Prefer many small classes containing small, focused functions and methods.
Effective Commenting
- Distinguish between good and bad comments.
- Learn how to write helpful comments and avoid redundant or unhelpful ones.
Day 2
Functions
- Focus on doing one thing only.
- Keep them small.
- Evaluate good vs. poor argument usage.
- Avoid unintended side effects.
Error Handling
- Determine when to handle errors locally versus allowing them to propagate.
- If an exception is caught, decide what to do with it and why.
- Create custom error handling classes.
Code Formatting: Techniques for improving code readability and consistency.
Test-Driven Design: An open discussion on Uncle Bob’s philosophy that programs should be developed using TDD.
Requirements
There are no specific prerequisites for attending this course.
Testimonials (2)
The teacher addressed many relevant topics for clean coding with practical examples.
Ben van Oeveren - Movella
Course - Clean Code
I really liked that there were a lot of practical exercises in which you could put the learned immediately into action.