Things are the way they are because they got that way

If you're working on a complex codebase and you're trying to understand the complexity by looking at the codebase then you're looking in the wrong place. That's like the man in Peopleware who loses his keys in a dark street and looks for them in the adjacent street because, as he explains, "the light is better there". A codebase is the way it is because it got that way. Slowly. Over time. If you're looking at the code your looking at the effect and not at the cause. It was the developers that did it!

Things are the way they are because they got that way.

Increase visibility

My sister Alix and I were chatting about work-related stupidity we'd imagined and experienced. Strict quotas on how much time you're allowed for going to the toilet for example. Naturally the time-allowed for no 2's would be longer than the time allowed for no 1s. But how would the managers police the quotas? The answer, we realized, was specialist plumbing. Take out the old copper pipes and put in clear perspex pipes instead. Plumb them through the managers office, at eye level. Purpose built hardware probes, available at reasonable cost, would measure the volume of shit. The probes would wirelessly connect to ShitLogger (tm) an app for monitoring the volume of shit against the quotas. To log the logs, as it were.


I've written before that:

Human beings have evolved a very strong association that cause and effect are simple and linear; that cause and effect are local in space and time.

One of example of this is when contestants on Who Wants To Be a Millionaire phone a friend. It's easy to think that the friend could simply watch the program and start trying to find the answer before they're called. They can't. What you're watching happened some time in the past. The program is not live.

Another example is this blog! At the recent ACCU conference several people commented on what a fast reader I was. I often blog three or four book snippets in a week. And I am learning to increase my reading speed. And I do read a lot. But it's an illusion. I have a stock of hundreds of books I've already read and all the best bits from them are already marked. I simply take a book from my shelf and blog the best of its best bits as a book snippet. And then put the book onto the ACCU charity book-stall pile.

Bad captcha

I had this yesterday. I doubt any human could read that! As my friend Niklas Bjornerstedt tweeted

captchas are getting so hard to read that only robots will be able to solve them soon

Accu conference charity book stall

Once again a big thanks to everyone at the accu conference who took a book and made a contribution to the two charities - Water Aid and The National Autism Society this year. The total raised was a smidgen under £600 which will be split equally. Thanks also to my son Patrick (he has Aspergers Syndrome) for lending me the safe. And thankyou too to several people who brought some books for the stall during the conference. I plan to repeat the stall again in 2012.

Deliberate practice booklist

Kevlin and I have just finished the accu pre-conference tutorial. A big thankyou to all the participants. The origin of some of the quotes was a little hard to read as the printed handouts were a little small. Here is a list of the books quoted:


Back to quotes table-of-contents

From Extreme Programming Explained
XP is a communal software development discipline.

From The Way of the Leader
A person who practices self-discipline and continuously develops his level of skill seldom fails in the long term.

Discipline is not intended to kill character, enthusiasm, and initiative, but to develop them.

From The Road Less Travelled and Beyond
The essence of this discipline of balancing is unlearning and "giving up" something in ourselves in order to consider new information.

All discipline is a form of submission.

From Zen Soup
Discipline is simply a matter of doing what we must, without wasting time or energy worrying whether or not we feel like it.

From The Long Walk to Freedom
I could compensate for lack of natural aptitude with diligence and discipline. I applied this to everything I did.

From Gandhi an Autobiography
Experience has taught me that silence is part of the spiritual discipline of a votary of truth.

From Good to Great
The purpose of bureaucracy is to compensate for incompetence and lack of discipline. Avoid bureaucracy and instead create a culture of discipline.


Some feedback quotes from previous blog entries: From Agile development in the large
Quick feedback should be the first thing you introduce.

From What did you say?
We structure our world so we will not receive feedback that threatens our view.
We don't even wait to ignore feedback, but actively take steps to prevent such feedback from ever happening in the first place.
Don't concentrate on giving feedback; concentrate on being congruent - responding to the other person, to yourself, and to the here-and-now situation.

From The dance of life
All societies depend for the stability on feedback from the people. Depersonalization reduces feedback to a minimum, contributing to instability and lowering the overall level of congruence in the society.

From Understanding the professional programmer
Many programmers… work in environments in which they receive essentially no real feedback embodying the consequences of what they do. Lacking no real feedback, they lack the motivation to attempt changes, and they also lack the information needed to make the correct changes.

From Quality Software Management. Vol 2. First-Order Measurement
Software development is not primarily a manufacturing operation for we (ideally) never develop the same software twice. This uniqueness of product means that Deming's "statistical signal" - though necessary - is not sufficient for feedback control, because there often isn't enough repetition - enough stability - to generate meaningful statistics.

From Quality Software Management. Vol 4. Anticipating Change
In a feedback control system it's only our perception that determines which is controller and which is controllee.

From The systems bible
Just calling it "feedback" doesn't mean that it has actually fed back. To speak precisely: It hasn't fed back until the system changes course. Up until that point it's merely sensory input.

From Talent is overrated

Practicing without feedback is like bowling through a curtain that hangs down to knee level. You can work on technique all you like, but if you can't see the effects, two things will happen: You won't get any better, and you'll stop caring.

From the Principles of product development FLOW
Fast local feedback loops prevent the accumulation of variance.

From the Aesthetics of change
All simple and complex regulation as well as learning involve feedback. Contexts of learning and change are therefore principally concerned with altering or establishing feedback.

Mozart a biography

is an excellent book by Piero Melograni (isbn 0-226-51961-9). As usual I'm going to quote from a few pages:
Mozart was great (among other reasons) because he knew how to have fun.
Some people believe that music flowed from him almost spontaneously, thanks to his genius. In reality, from earliest childhood he practiced for thousands of hours every year.
He lived only thirty-five years, but he lived them at a wolf's pace and went far in that short time.
In a letter dated 20 August 1763, Leopold Mozart relates that in many places in Germany the well water was so bad, smelly, and muddy that it was habitually mixed with wine. It was worse in Paris. Parisians drank the repugnant water of the Seine, into which the city's garbage was thrown. The Mozarts, like many others, let it settle in a pitcher for a few hours, where it formed a worrisome solid layer.
In a letter dated 1 April 1764 Leopold reported that when an eclipse of the sun had occurred, Parisians rushed into the churches to protect themselves from being poisoned by the air during the temporary disappearance of the sun's light.
Wolfgang fell seriously ill with smallpox. He was blind for nine days and hovered between life and death, for the second time, after his bout with typhus in 1765.
Mozart performed several times on the harpsichord, astonishing his listeners with the agility of his hands, his left hand in particular. Some Neapolitans, perhaps influenced by a culture that tended to superstition and like mysteries. asserted that the boy played as well as he did thanks to a magic ring that he wore. When they demanded that he take off the ring and play without it, they saw that his playing depended on talent rather than spells, and they applauded all the more.
In those days, a composer would not dream of writing the arias for an opera without consulting the singers who were to interpret them… composers were craftsmen, paid by the piece, and were completely subservient to the true superstars of the age, who were the singers.
In those days no one hesitated about applauding in the middle of a work of music.
His fingers were deformed, either because of continual keyboard exercises from childhood on or from arthritis.
Only artists capable of innovation can give a long life to their works. Innovation prompts tension, curiosity, and awe.


Back to quotes table-of-contents

From The Way of the Leader
Do the essential things well: Be proactive (do through action), Reduce complexity (concentrate effort on the essential things), Seek improvement (get the essential things done better).

From Everyday Heroes of the Quality Movement
Automating complexity is never as effective as removing it.

If you automate without first getting rid of complexity, you cast the complexity in concrete.

From Simplicity
The human brain is a very simple system that is capable of working in a complex way, rather than a complex system.

From Patterns of Software
In the modern era, we have come to favor simplicity over complexity, perfection over imperfection, symmetry over asymmetry, planning over piecemeal growth, and design awards over habitability.

From The Gift of Time
Complexity isn't an attribute; it's a relationship.

From General Principles of System Design
Complexity is a relationship between system and observer.

From The End of Certainty
A nonequilibrium system may evolve spontaneously to a state of increased complexity.

From The Systems Bible
A complex system that works is invariably found to have evolved from a simple system that worked.

From Surfing the Edge of Chaos
Recent study of evolution, both in the natural world and in computer based complex systems, has demonstrated the surprising result that the presence of parasites in a system accelerates evolution dramatically.

From Consilience
Complexity is what interests scientists in the end, not simplicity.

From Adapt - why success always starts with failure
Complexity is a problem only in tightly coupled systems.

From General Principles of Systems Design
There is a tendency for complexity in models to rise as the time between sensing and acting grows.

Photo by Kevin Wong.

Effective leadership masterclass

is an excellent book by John Adair (isbn 0-330-34785-3). As usual I'm going to quote from a few pages:
Every person and thing is only what it is in relation to others. [Lao Tzu]
It is this quality of doing things spontaneously and in an unselfconscious way, without regard to their effects upon other people's perceptions of oneself.
The natural badge of such inner humility towards all things is silence.
I believe the first test of a truly great man is his humility. [John Ruskin]
I cannot hear what you are saying because you are shouting at me. [Zulu proverb]
So many people are loath to make irrevocable decisions, are tepid in their enthusiasms. [Ordway Tead]
I do not say that the men of the 14th Army welcomed difficulties, but they grew to take a fierce pride in overcoming them by determination and ingenuity. [General William Slim]
Change and leadership are closely linked.
Leadership is of the spirit, compounded of personality and vision; its practice is an art. Management is of the mind, more a matter of accurate calculation of statistics, of methods, of time tables, and routine; its practice is a science. [General William Slim]
Leadership is bound up with culture.
As a natural leader, he [Gandhi] led by example - spinning for at least an hour every day.

We'll never survive!

One of the books for the accu charity book stall is my copy of Extreme Programming Explained by Kent Beck (1st edition).
One of the entries in its bibliography is a quote from The Princess Bride.
Buttercup and Westley are about to enter the Fire Swamp and face it's three terrors: the Flame Spurts, the Lightning Sand, and the Rodents Of Unusual Size (R.O.U.S.'s).

Buttercup says to Westley (Kent misquotes slightly here):

We'll never survive

and Westley replies:

Nonsense - you're only saying that because no one ever has.

I just love this line. And I love Kent's idea of putting a film quote in the bibliography. I love that it's in the bibliography in a section called "Attitude". I think Kent is hinting at their courage - that depending on your attitude life can be an adventure. After surviving the flame spurts Westley says to Buttercup:

Well now, that was an adventure.

And a bit further on he says:

The Fire Swap certainly does keep you on your toes.

Just before facing the R.O.U.S.'s Buttercup says:

We'll never survive - we may as well die here.

To which Westley replies:

No. No. We have already succeeded.

I love that line too. (I pretty much love every line of the film.) Again it's about attitude. As they make it out of the fire swamp Buttercup says (almost in disbelief):

We did it.

And Westley says:

Now, was that so terrible?

Caring about yourself.
Caring about others.
Caring about the code.

The nature and art of workmanship

is an excellent book by David Pye (isbn 1-871569-76-1). As usual I'm going to quote from a few pages:
Design is what, for practical purposes, can be conveyed in words and by a drawing: workmanship is what, for practical purposes, can not.
The essential idea is that the quality of the result is continually at risk during the process of making.
The care counts for more than the judgement.
Much of what is ordinarily called skill is simply knowledge.
There is a strong incentive to design only in terms of shapes which are easy to communicate.
No two leaves of the same tree are precisely alike, each is individual: yet every one of them conforms to a recognizable pattern characteristic of the species.
Design - the music of design - depends on the relationships between distinguishable and separable features of things.
It [workmanship] takes over where design stops.
You must not torture your material.
We can have no direct rapport with the nature of any material, but have to judge what it is by looking at the surface. We can never see the thing, the material itself, but only the surface, which our vision, unlike X-rays, will not penetrate.

Forward declaring std::string in C++

One type you can't forward declare in C++ is std::string
class string; // Computer says no
This does not say a lot but what it does say is that string is a class and unfortunately it's not - it's a typedef of basic_string<...>

If I compile a file containing just the line
#include <string>
then g++'s -H flag tells me that pulls in over 100 other header files! Avoiding those #includes might make an appreciable difference to build times in some C++ codebases. You can fake an std::string forward declaration by using a type wrapper. For example:
#ifndef EG_HPP
#define EG_HPP

class fwd_string; // instead of #include <string>

void eg(const fwd_string &); 
// instead of
// void eg(const std::string &);

Where fwd_string.hpp looks like this:

#include <string>

class fwd_string
    fwd_string(const char *);
    fwd_string(const std::string &);
    std::string string;

You can also use this "type-tunneling" technique to forward declare enums in C. I've never seen this used in anger in an actual codebase. It's just an idea. Caveat emptor.

Accu conference charity book stall

Once again I'm going to give away a load of books at this years ACCU conference. As before I'll choose a charity and ask everyone who takes a book to make a voluntary donation. I've already collected two boxfulls. If you're coming to the conference please consider bringing along some books and contributing them to the stall.