Oana Sipos's Reviews > Clean Code: A Handbook of Agile Software Craftsmanship

Clean Code by Robert C. Martin
Rate this book
Clear rating

by
7205156
's review

bookshelves: currently-reading

These are rather notes than a review while reading:

1. Use very descriptive names. Be consistent with your names.
2. A function should not do more than one thing.
3. SRP (Single Responsibility Principle): a class or module should have one, and only one, reason to change.
4. Stepdown rule: every function should be followed by those at the next level of abstraction (low, intermediate, advanced).
5. A long descriptive name is better than a short enigmatic name. A long descriptive name is better than a long descriptive comment.
6. The ideal number of arguments for a function is zero (niladic). Next comes one (monadic), followed closely by two (dyadic). Three arguments (triadic) should be avoided where possible. More than three (polyadic) requires very special justification and then shouldn't be used anyway.
7. Flag arguments are ugly. Passing a boolean into a function is loudly proclaiming that this function does more than one thing. It does one thing if the flag is true and another one if the flag is false.
8. Write learning test when using third-party cody to make sure it behaves the way you expect it to. And if codebase changes in time, at least you find out early enough.
100 likes · flag

Sign into Goodreads to see if any of your friends have read Clean Code.
Sign In »

Reading Progress

March 8, 2015 – Started Reading
March 8, 2015 – Shelved
March 8, 2015 –
page 2
0.46%
June 30, 2015 –
page 17
3.92%
July 1, 2015 –
page 25
5.76%
July 2, 2015 –
page 31
7.14%
July 5, 2015 –
page 42
9.68%
July 6, 2015 –
page 52
11.98%
July 6, 2015 –
page 52
11.98%
July 14, 2015 –
page 65
14.98%
July 16, 2015 –
page 75
17.28%
July 21, 2015 –
page 80
18.43%
July 24, 2015 –
page 93
21.43%
July 26, 2015 –
page 93
21.43%
July 26, 2015 –
page 103
23.73%
August 2, 2015 –
page 107
24.65%
August 4, 2015 –
page 111
25.58%
August 5, 2015 –
page 118
27.19%

No comments have been added yet.