Home » Opinion » The Psychology of Programming

The Psychology of Programming

Over the past week, I’ve listened to and read several articles that have started me thinking more about the Psychology of Programming.

Not that I haven’t been thinking about this for a while.  I’ve been quite intrigued by human behavior for a while now.  But more recently, there was this podcast over on dotNetRocks about “Punishment Driven Development”. And this comment:

The happiest people in my experience are those that have options. They have transferable skills, see their employment as a personal choice, have self confidence that they are providing value to the company and are in a position professionally and personally where they could change job if they needed. The feeling of being trapped in a position from which you can’t escape (either a dissatisfying job, bad manager or whatever) will lead to negativity.

Which I almost agree with, except I think it is the negativity that leads to feeling trapped.

And then there is the book I am reading, “Influence: The Psychology of Persuasion” which goes into detail on why we make decisions that seem to go against our better judgment.

Then there is another podcast that discusses the decisions we make as we start a new JavaScript project.

And all of this culminates into the following thoughts:

The Psychology of Programming
Photo credit: deltaMike via VisualHunt.com / CC BY

What Makes You Happy?

It really does amaze me that I work with people who seem so unhappy with their work place and yet, aren’t making any effort to find another place to work.  As a consultant with nearly 30 years of experience, I can tell you first hand that some places are better than others to work.  There is probably a place for you if you’d just try to find it.

Or, maybe the problem is you.  Maybe you’ve never liked working. Or maybe you like complaining.  Maybe being happy is an attitude and isn’t really dependent on our circumstances.  Maybe, the happy people like their jobs?

Or maybe it is just easier to blame the company than to take responsibility.  I find happy people take action.  Make opportunities.  Learn new stuff.  The unhappy people I know blame something or someone for who they are.

It’s All in your Head

Here is a scary thought though.  All your ways of reacting to events in your life are learned responses.  Most of those responses you learned before you were 5.  But, here’s the good news.  Since they are learned responses, you can, if you want to, re-learn responses.

We all have behaviors we don’t like.  Some of us get angry for stupid stuff.  Some of us over eat.  Some drink too much.  Some smoke.  In almost all cases, the behavior isn’t the real issue.  The question we need to ask ourselves is why do we do those things?  In what way to we believe doing these things is going to help us?  What would you need to believe differently in order to change?  What is keeping you from believing something different?

It’s Just an Opinion

I have a rule.  “Never argue about opinion.”  I’ll present why I believe something is true.  State all my reasons.  Clarify if I think that is necessary.  But as soon as I realize that the discussion has turned into an argument where no one is going to convince the other of anything.  I disengage.  This is why some blog comments never get answered.

Not everything is opinion.  I’ve had people leave comments correcting my understanding and pointing to authoritative documentation that says they are right.  Thank you.  But, in the grand scheme of life, there is very little that falls into the realm of fact.  Most of what we argue about as programmers is opinion.

What is interesting about opinion is that the more you know about a subject, the more opinionated you are likely to be.  That can be a good thing.  Show me a programmer who doesn’t have opinions and I’ll show you a programmer who is just doing what they’ve been told to do.  Show me a programmer who has an opinion but can actually argue multiple sides of an argument and I’ll show you a programmer who really knows his stuff.  If you hold opinions so strongly that you are offended when someone disagrees with you, you have an issue.

Herd Mentality

For years, it has puzzled me how, as a community, we can know that writing unit test for our code is a worthwhile activity, and yet hardly anyone I know does this.  Truth be told, it is a struggle even for me.

But, here’s an interesting fact.  We tend to do what we SEE others doing.  If no one on your team is writing test, you think, “we don’t write test here.”  This behavior explains why, in test after test, groups will ignore people who need help while individuals by themselves will provide aid.  This impacts a lot of our life if you think about it.  How many times have I assumed that someone else is going to call the power company when the power goes out during a snow storm?  Certainly, if the whole street is impacted, someone will call.

The very fact that it has impacted the whole street is indication enough that no one else has called.  I hope I remember this the next time the power goes out.

Appeal to Authority

Another scary statistic is that people will do whatever they are told to do if an authority figure has told them to do it.  If there is any question about what we should do, we will try to figure out what the authority figure wants.

This is how con men work.  In a very scary experiment, a “doctor” calls the nursing desk and tells the person who answers the phone to administer a drug to a patient.  The problem is, the prescription is too high and is of a drug that is not approved for the nurses to give.  Yet, because a doctor has said so, they are willing to comply

In a more humorous example, a patient had an ear ache in their right ear.  The doctor left a note with instructions to administer ear drops to the R ear.  So, the nurse administered ear drops to the patients rear.  Neither the nurse nor the patient questioned the instructions.

Oh, but that would never happen to programmers now.  Or would it?

Again, I go back to the point of testing.  I can’t tell you how many times I’ve heard programmers tell me they “aren’t allowed to write unit test.”  For the most part, I’m not sure anyone asked, they are just assuming that the boss won’t let them because of the Herd Mentality I mentioned above.  But let’s assume the boss really has made such an edict.  Is that a good reason to not tests?  I’m not sure it is.  At least no more so than administering ear drops to someone’s butt.

But I’ve also seen this behavior first hand.  I was on a project once where the organization claimed to be “Agile.”  For the most part they were.  They worked iteratively.  They had something resembling sprints. But a “boss” several layers up the ladder who we never saw had “instructed” the team to do this project using a waterfall approach because “we already know what this product is supposed to do.”

The problem is, while this project was a rewrite of an older system, the rewrite encompassed many changes to the existing system.  So, even using that argument, using waterfall made no sense.  But, everyone on the team also knew that what made a project an agile project vs a waterfall project had a lot more to do with being able to adjust.  Why no one ever told the manager he was wrong is beyond me.  What is further interesting is that even though that project received a new manager, the team STILL tried to obey the old rule because they hadn’t been given an alternate direction.

Inertia

The famous last words of every dying group are, “But, we’ve never done it that way before.”  Why?

Did you know that people will work twice as hard to keep the dollar in their pocket than they will to gain an extra dollar?  This explains so much of human behavior for me.  This is why startups have such an advantage over established companies.  The startup has nothing to lose.  As soon as they feel like making a change will cause them to lose something important, they’ll stop innovating.  They become the established company.  If an established company can survive long enough to have nothing to lose, they might innovate.  For an example of this, check out the turn around of both Apple and Microsoft.  If you look very closely, you’ll see that Apple is moving into the “we have something to lose” cycle.  (Don’t bother flaming me, I have no religious preference for either company.)

Now how does this apply to you as the lonely programmer?

Well, back to our sad programmer example.  Could it be that our sad programmer doesn’t change jobs because he’s holding on to his dollar instead of trying to get a new one?

Could it be you aren’t testing your code with formal unit test because you are holding onto your dollar?

When is the last time you tried anything new?

Break Free

And so, the question naturally becomes, “How do we break free?”

So much of this is a part of who we’ve learned to be.  Many of our behaviors have helped us get to where we are.  But like the company who has moved from startup to established player, we need to become comfortable with being uncomfortable so that we can not just break free, but break into a better version of ourselves.

Maybe you are comfortable where you are.  I don’t know.  Personally, I’m always trying to improve.  I’d much rather have the new dollar than keeping the dirty old one.  You might have a different set of values.  Maybe a different opinion.

I could be wrong.  But, what if I’m right?

 

Other post in Opinion
Summary
The Psychology of Programming
Article Name
The Psychology of Programming
Description
Over the past week, I’ve listened to and read several articles that have started me thinking more about the Psychology of Programming. Not that I haven’t been thinking about this for a while. I’ve been quite intrigued by human behavior for a while now. But more recently, there was this podcast over on dotNetRocks about “Punishment Driven Development”. And this comment: The happiest people in my experience are those that have options. They have transferable skills, see their employment as a personal choice, have self confidence that they are providing value to the company and are in a position professionally and personally where they could change job if they needed. The feeling of being trapped in a position from which you can't escape (either a dissatisfying job, bad manager or whatever) will lead to negativity. Which I almost agree with, except I think it is the negativity that leads to feeling trapped. And then there is the book I am reading, “Influence: The Psychology of Persuasion” which goes into detail on why we make decisions that seem to go against our better judgment. Then there is another podcast that discusses the decisions we make as we start a new JavaScript project. And all of this culminates into the following thoughts:
Author
DMB Consulting, LLC

About Dave Bush

Dave Bush is a Full Stack ASP.NET developer focusing on ASP.NET, C#, Node.js, JavaScript, HTML, CSS, BootStrap, and Angular.JS. Does your team need additional help in any of the above? Contact Dave today.

Leave a Reply

8 Comments on "The Psychology of Programming"

Notify of
avatar
Sort by:   newest | oldest | most voted
trackback

[…] The Psychology of Programming (Dave M. Bush) […]

Big_Phill
Guest
A very interesting read and much of it could be applied outside of programming, politics for example rings true to much of what you’ve written. I believe I am fortunate to be happy in my current role precisely because I know I have transferrable skills that could quite easily land me a lucrative contracting role should my employer choose to dispense with my services. However in the spirit of hopefully “correcting your understanding” as you put it I would suggest that “I’ll show you a programmer who really knows his stuff” should be changed to “I’ll show you a programmer… Read more »
P Kemner
Guest
Herd mentality and general inertia do play a part, but I think that some programmers can be “trapped” in a bad environment, especially if they don’t live in an IT hot spot with plenty of jobs, and can’t move to a high cost-of-living area. Sure, they could self-study and learn new languages, but most employers won’t consider hiring them unless they’ve already been paid to write in that language. I also think that replacing “programmer” with “coder” has brought the attitude of “You’re paid to type code, not to think, plan, and test” to many workplaces. Until something goes wrong,… Read more »
Order23
Guest

but the dollar in your pocket is worth more than the dollar you earn, because taxes.

Br. Bill
Guest
There is a mentality in the modern software development world that says it’s way better to constantly tip over everything you’re doing and use the newest fresh hip thing. If you do professional development long enough (I’ve been at it 30 years), you just get tired of the churn. It’s not negativity. It’s a realistic reaction to chaos. People who say “I thrive in chaos” ignore the long-term effects of living in a constant state of infrastructural change that may or may not be necessary. If building roads were like building software, every neighborhood would be a patchwork of 10… Read more »
Dalton
Guest
I designed software in the 80’s for startups mostly. You seemed to be describing the mindset (as a goal) of the “hired guns” who did this kind of work. I was previously a professional musician then telecommunications quality engineering technologist with the ability to acquire new operating environments (e.g., apply previous concepts and rapidly acquire new) and had the pleasure of working with similarly eclectic folks, e.g., music, math and computer sci majors (one coming by way of former career in television show production). I glanced at your linkedin data and am impressed with the vitality that must fund this… Read more »
Overlord_of_the_Peanut_Gallery
Guest
Overlord_of_the_Peanut_Gallery

Improve morale by firing all the unhappy people! There, my work here is done 🙂

Hr Habib
Guest

very interesting article, thank you

wpDiscuz