Clean Coder: Commitments
Clean Coder: Commitments
‘Clean Coder’ by Robert C Martin. Here are important quotes from the book.
1) Professionalism
If a nonprofessional makes an error, the employer cleans up the mess. But when a
professional makes a mistake, he cleans up the mess.
As you mature in your profession, your error rate should rapidly decrease towards the
asymptote of zero. It won’t ever get to zero, but it is your responsibility to get as
close as possible to it.
How can you know your code works? That’s easy. Test it. Test it again. Test it up.
Test it down. Automate your tests. Write unit tests that you can execute on a
moment’s notice, and run those tests as often as you can. Every single line of code
that you write should be tested. write your tests first, before you write the code
that passes them.
Perhaps you don’t want to make that kind of commitment. That’s fine, but you should
not then think of yourself as a professional. Professionals spend time caring for their
profession.
when a professional finds himself the butt of a joke, he’ll be the first to laugh
Professionals will pursue and defend their objectives as aggressively as they can. your
manager is counting on you to defend your objectives as aggressively as he defends
his. That’s how the two of you are going to get to the best possible outcome.
Commitments:-
Creating a language of commitment may sound a bit scary, but it can help solve many
of the communication problems programmers face today—estimations, deadlines, and
face-to-face communication mishaps. You’ll be taken as a serious developer who lives
up to their word, and that’s one of the best things you can hope for in our industry.
Creativity:-
I learned a long time ago that creative output depends on creative input. I read a
lot, and I read all kinds of material. I read material on software, politics, biology,
astronomy, physics, chemistry, mathematics, and much more. However, I find that the
thing that best primes the pump of creative output is science fiction.
When you are stuck, when you are tired, disengage for awhile. Give your
creative subconscious a crack at the problem. You will get more done in less time. .
There is something about disengagement that allows your mind to hunt for solutions in
a different and more creative way.
regularly measure your progress against your goal, and come up with three fact-based
end dates: best case, nominal case, and worst case. Be as honest as you can about all
three dates. Do not incorporate hope into your estimates!
not agree to work overtime unless (1) you can personally afford it, (2) it is short
term, two weeks or less, and (3) your boss has a fall-back plan in case the overtime
effort fails.
If you are a Java programmer, contribute to a Rails project. If you write a lot of
C++ for your employer, find a Python project and contribute to it.
it should be the goal of the development group that QA find nothing wrong.
Choose disciplines that you feel comfortable following in a crisis. Then follow them all
the time. When the going gets tough, trust your disciplines.
A gelled team usually consists of about a dozen people. It could be as many as twenty
or as few as three, but the best number is probably around twelve. once it happens,
it’s magic. A gelled team will plan together, solve problems together, face issues
together, and get things done.
allocate projects to existing gelled teams, they don’t form teams around projects.
Teams are harder to build than projects. Therefore, it is better to form persistent
teams that move together from one project to the next and can take on more than
one project at a time. The goal in forming a team is to give that team enough time
to gel, and then keep it together as an engine for getting many projects done.