Locus of Control and Learned Helplessness in Coding


Locus of Control and Learned Helplessness in Coding


April 17, 2021

personal favorite

Have you ever felt like coding is an uphill battle, where you’re constantly fighting the computer without any real hope of ever making progress? Have you ever given up trying to learn something? Have you ever felt like you’re not cut out for any of this? Great news, that’s totally normal in computer science! The bad news is, that’s totally normal in computer science.

I’ve struggled with these feelings myself, and I see them all the time in the people I work and learn with. This article collects a few ideas that have helped me conceptualize these feelings, with the hope that it might help other folks with similar thoughts.

Locus of Control

Locus of control is a way to talk about whether you feel like you’re in control. Do you control what happens, or are you at the mercy of your environment? Do you happen to the world, or does the world happen to you?

  • People with an internal locus of control believe they are responsible for what happens. “I got a bad grade on the test because I didn’t study hard enough!”
  • People with an external locus of control believe other factors (like people, institutions, or luck) are responsible for what happens. “The teacher gave me a bad grade on the test because the class didn’t teach me what I needed to know.”

You might assume that an internal locus of control is “better” than an external locus of control, but I think they both have pros and cons. People with an internal locus of control are probably more motivated, but they also probably blame themselves and stress out over things they don’t actually control. People with an external locus of control might find it harder to stay motivated, but are also probably better at pointing out problems around them.

Of course this is an oversimplification, but I see this all the time in myself and my fellow programmers. Let’s say you’re coding and you encounter an error. What’s your reaction?

“Intellij is giving me a red underline and my code doesn’t work. Java is so buggy!”

or

“I’m getting a compiler error and I’m not sure what it means. I must have misunderstood something, so I need to google the error message to learn more and fix my code!”

That might seem contrived, but I see that first reaction all the time, especially in new coders. That’s one reason I recommend focusing on the fundamentals: if you don’t have the vocabulary to talk about what’s happening, you’re not going to feel like you’re in control of your own code.

As I’ve become a little more senior in my job, I’ve noticed this idea of locus of control in other aspects of my career as well. For example, let’s say your boss gives you a project you don’t like. What’s your reaction?

“I don’t want to work on this, but oh well, there’s nothing I can do about it.”

or

“I think we should be working on something else, and it’s my job to convince my team of that.”

This is fodder for a separate blog post, but realizing that I had agency and even a responsibility to advocate for my ideas is one of the most important lessons I learned on my journey to becoming a “senior” software engineer.

Learned Helplessness

Learned helplessness is the idea that if you start with having no control over a situation, it’s really hard to realize you do have control when you finally get it.

Back in 1967, an experiment was done on three groups of dogs:

  1. Dogs in group 1 were not shocked.
  2. Dogs in group 2 were shocked, and they could end the shocks by pushing a lever.
  3. Dogs in group 3 were shocked, but they could not end the shocks.
    • (Actually their shocks ended when the dogs from group 2 pushed their levers, because apparently shocking a bunch of puppies wasn’t messed up enough.)

Then the three groups were put into a new cage. This new cage had two halves, separated by a fence the dogs could jump over. Shocks were given in one half of the cage, and the dogs could avoid the shocks by jumping to the other half.

The dogs in group 1 and group 2 quickly learned this trick, and were able to escape the shocks. But the dogs in group 3 gave up, laid down, and didn’t even try to escape the shocks.

dog

In other words, the dogs in group 3 had learned that they were helpless, that getting shocked was just a part of life, and that nothing they did would change it. Even though they were in a different situation and could just jump over the fence to escape the shocks, it didn’t even occur to them as an option. In fact, the scientists had to physically pick the group 3 dogs up to teach them that they could escape the shocks at all, showing that it’s really hard to “unlearn” learned helplessness.

Funny enough, I originally heard about learned helplessness right after I started at Google, in a training that, in hindsight, was meant to teach managers how to inspire their reports. Even more than the idea of locus of control, I see learned helplessness almost every single day. Here are a few examples:

  • “I’ve tried to learn JavaScript and it was too hard, so I gave up.”
  • “That part of the code is really buggy, so nobody touches it.”
  • “Management will never let us work on anything interesting, so why bother?”

I have personally felt some form of all of these myself. These feelings of helplessness come from valid experiences, but the problem is that they can outlive their usefulness. Just like the dogs who didn’t even try to jump over the fence, we often resign ourselves to unhappiness because we assume there’s no alternative.

I am by no means immune to this. The reason I find this so interesting is because I see it in myself just as much as I see it in others. But the truth is that JavaScript was a lot easier to learn than I thought it would be, that bugs often take 5 minutes to fix once I get started, and that some of the most interesting and most successful moments of my career have come from advocating for changes I thought nobody would agree to.

What do you feel helpless about? Are you sure you’re really helpless, or is it time to try to jump over the fence?

Impostor Syndrome

Impostor syndrome is the feeling that you’re “faking it” through your career. You feel like everyone around you knows what they’re doing, while you’re secretly unqualified. If they ever found out that you have no idea what you’re doing, they’d immediately fire you!

I think the idea of impostor syndrome has its own set of problems (for example blaming individuals for institutional dysfunctions), but the truth is that pretty much everybody in tech feels impostor syndrome. Including me!

I’m mentioning impostor syndrome because I think it’s tied up with locus of control and learned helplessness. Feeling like your peers possess something you don’t (external locus of control) coupled with feeling like you’ll never obtain it (learned helplessness) is a powerful mix. I don’t think I’m going to “cure” impostor syndrome in this blog post, but I’ve found that thinking about why I’m feeling it is pretty helpful.

Burnout

Burnout is feeling exhausted or just plain angry when you think about your job.

If impostor syndrome is learned helplessness coupled with an external locus of control, I think burnout is the other side of the coin: learned helplessness coupled with an internal locus of control. In other words, burnout happens when you feel responsible for changing things, but you’ve learned (over and over again) that you can’t.

I don’t have any great insights or solutions here, and this is something I struggle with quite a bit myself. But I’ve found it helpful to deconstruct my feelings, and I often find the ideas of locus of control and learned helplessness at the core.

Helping Others

So far I’ve focused on how locus of control, learned helplessness, impostor syndrome, and burnout affect individuals, or how they’ve affected me. But I also think it’s interesting to observe how these affect teams, organizations, and entire companies.

For example, what does it feel like for somebody with an internal locus of control to have a manager with an external locus of control? How can you recognize learned helplessness in the people around you, and how can you help them overcome it? What institutional barriers are there that prevent people from believing they can change things?

I’m not going to pretend to have great answers to those questions, but I think they’re fascinating to think about. Hopefully this helps you feel a little less helpless, or at least helps you know that you’re not alone.

Now let’s all try jumping over that fence.

Comments

Happy Coding is a community of folks just like you learning about coding.
Do you have a comment or question? Post it here!

Comments are powered by the Happy Coding forum. This page has a corresponding forum post, and replies to that post show up as comments here. Click the button above to go to the forum to post a comment!