Programming is craftsmanship and requires skills
Many managers think that programming is easy, it's just a bunch of
for
, if
, else
and switch
clauses after all, isn't it ?
But coding is difficult because it is mainly about TAKING DECISIONS ALL THE TIME.
Driving is easy because you don't have to take decisions about the way to turn the steering wheel; walking is easy, you don't even have to think about it; Drilling a 10 mm hole into a wall is easy because the goal is clear and because you don't have many options to achieve it...
Software is difficult and is craftsmanship because there are always many
ways to achieve the same task. Take the simplest example I can think
about : an addition function : we want to add a
and b
to get
c=a+b
.
* Should I code this the object-oriented way ( a.add(b)
) or the
procedural way ( add(a,b)
) ?
* How should I name this ? add()
? sum()
? How should I name the
arguments ?
* How should I document the function ? is there some project conventions about it ?
* Should I return the sum or store it into the object itself ?
* Should I code this test first (TDD) ? write an UT afterwards or write no test at all ?
* Does my code scale well ? does it use a lot of memory ?
* Which visibility for this function ? private, public, package ?
* Should I handle exceptions (a is null for instance) or from the caller ?
* Should the arguments be immutable ?
* Is it thread-safe ?
* Should this function be injected within an utility class ?
* If I'm coding in object oriented, is it SOLID compliant ? what about inheritance ? ...
* ... tens of others questions any good coder should ask to himself
If all of this decisions could be taken by a machine, coders would not be required at all because we would just generate code (and we sometimes do it using MDD technologies, mainly for code skeletons with low added value).
We -coders- would then all be searching for a new job. But, AFAIK, this is not the case, we are still needed, still relevant. All companies still need costly software craftsmen !
Q.E.D. ;-)
I can't agree more with the manifesto for software craftsmanship.