DEV Community

Carlos Diaz for The Odin Project

Posted on

Memorization and learning to code

Memorization equals learning.

For many of us, it’s how our understanding was assessed. We were praised for memorizing the alphabet, numbers, the four nucleotides in DNA, and x is equal to negative b plus or minus the square root of b squared minus 4ac all over 2a. I imagine that somewhere out there my former math teacher is smiling.

Many of us have held on to that belief. I did when I was learning my programming basics. I spent so many hours attempting to memorize the syntax of a for loop. So many evenings where I’d try to recite the names, syntax, and return values of array methods. And many nights where I read and re-read the documentation on React, wishing I could just tattoo it to my brain.

I’ve spent the past few years helping people learn to code at The Odin Project and I’ve noticed a lot of people there are doing the same. At least a few times a week folks come in to our Discord server to ask about the best note-taking techniques or to express concern about moving to a new topic for fear of forgetting what they just committed to memory.

Here’s a hard truth: the concept that you spent hours trying to memorize that you feel has finally stuck- you’re going to forget it. Don’t freak out though. That’s ok. That’s normal.

The greatest concern I had once starting my job as a software engineer was whether I had enough in my brain. I was afraid of pairing with more experienced engineers at work because I didn’t want them to discover how little I knew. When we did pair I was embarrassed that I couldn’t recall a syntax for a some method or recall the return value of another. There was a pairing session I had with my colleague, John, where this all changed.

While pairing on a task, the idea of localStorage came up. I mentioned that I used it a few times in the past, hoping to impress my new co-worker. John invited me to tell him about it. There isn’t a way to dress this up: I FREAKED OUT. I couldn’t think of a thing to say. I apologized and said I forgot everything about it. But I gave myself a few seconds to think and finally told him there was a way to set and retrieve information but I had nothing beyond that. I was afraid of his response. I was expecting he’d say it’s crazy I hadn’t memorized everything about localStorage and go tell my boss that hiring me was a mistake. Instead, John shared something like this. His exact words are hazy but the spirit of it was:

“That’s ok. I haven’t used that in years myself. Let’s google it together and figure this out.”

The conversation continued and I remember little about the technical stuff. The fact that he didn’t flip out was shocking and that stuck with me. At the end of the pairing session, we discussed the need of revisiting documentation. John shared that he googles and reads documentation regularly. And shared that it is very normal to not have everything memorized. I always imagined that great engineers knew everything. I imagined they carried all their knowledge all the time and could recite any of what they held in their brain whenever they wanted. After all, I was under the impression that memorization equaled learning, which in turn led me to believe that I was only as good and skilled and useful as my memory. John taught me that this is far from the truth.

Now that I’ve been in the field for a few years, I find that I very much agree with the sentiment that John shared. I regularly forget how to use stuff. I forget syntax, return values, even names of methods. If I haven’t used Flexbox in a while, I’ll need remind myself on how to center a div. But rather than freak out, like I used to, I know that I can visit documentation to refresh myself on things when I need it.

When we are actively engaged with a topic, that topic is easy to carry in our working memory. And the hope is that our efforts in studying a thing will move that thing into our long-term memory. For many, falling short of putting everything we engage with into our long-term is failure. Moving things from our working memory to our long-term memory is hard. And to make matters worse, working memory is not unlimited. This means that as we become familiar with one thing, another thing will fall out of that working memory. This causes concern to a lot of people. We end up returning to things we feel we’ve forgotten every time we learn something new. Except in revisiting that thing we forgot, we now risk forgetting that thing we just learned. Then we’re in a cycle where we’re constantly trying to hold on to everything at once. And if we’re constantly trying to hold on to what we know, what room do we have for learning new things in peace?

In the real world, no one holds on to everything all the time. We’re more likely to hold on to the general idea of a thing and less likely to hold on to the details. And in the adventure of learning to code, there is little difference in the utility between perfect memorization and being vaguely aware.

Knowing that it’s possible to remove the last element of an array is just as good as having the syntax of JavaScript’s pop method memorized.

❗ FULL DISCLOSURE ❗: As I typed the sentence above, I was like: “is the pop method even the one that removes the last element of an array?" Me 2 years ago would have freaked out and felt real sorry for myself. Not this time. I cracked open a browser tab and looked at the documentation and confirmed that was the case. Cool!

As we engage with ideas over time, we’re more likely to move larger concepts into our long term memory than the finer details associated with those concepts. As with the example above, we’re more likely to remember that there is some way in JavaScript to remove last element of an array instead of perfectly memorizing everything about the pop method.

We can’t memorize everything. But we can become aware of a ton. Equipping ourselves with awareness of what to research is good enough for getting through learning. Over time, and with lots of practice and mistakes and experimentation, things will stick.

Being vaguely aware is enough.

Disclaimer:

Having some stuff memorized by the time you get to interviews is useful. But by the time you get there you'll be surprised by how much has stuck. The thoughts I’ve shared here are specifically for folks actively in the learning process.

Latest comments (39)

Collapse
 
a_a_hajji profile image
Ahmed abdirahman • Edited

I remember trying to memorize programming syntax taking lots of note , passively reading or looking at code samples hoping to memorize or remember them. But then I realised later something that was whatever you want to learn just understand the concept and big picture, even If you stuck at understand a concept Move on keep on learning somewhere and later years it will click onto your mind. That concepts you don't understand now could relate other concepts in the line later on your learning process. Keep learning don't hold your mind on tiny concepts try understand the big picture and move on.
Right now I'm talking there’s projects I've built with my own and projects in course I don't know what is going under the hood like some (functions,methods, a Concept or syntax)but the pig picture and the why. I almost revisit them. Even some concept come on the way with different projects. 🧩⏰

Collapse
 
donavanc13 profile image
Donavan

This article was great, really insightful. It helped me. Reevaluate my perspective of what learning something new really means

Collapse
 
idkitti profile image
Kitti • Edited

It helped me a lot.

Collapse
 
debbie1505 profile image
debbie1505

This is so good and is really going to help me learn better going forward. I've always have shame with forgetting syntax, and I've always thought I should remember syntax for me to consider myself a programmer. But this article took that shame away and validate that it is okay to forget syntax and it is okay to google stuff. And a statement that stood out to me is "Knowing that it’s possible to remove the last element of an array is just as good as having the syntax of JavaScript’s pop method memorized.". And now I'm going to focus on being aware of ways to solve a problem instead of remembering each syntax, I could just google it.

Collapse
 
frontendfungi profile image
FrontendFungi

This is very encouraging. I let out a big sigh of relief after reading this article. If simply remembering that something exists is good enough most of the time, then I will try not to stress about memorizing. Thanks, Carlos! ⚡

Collapse
 
adriand profile image
Adrian Dobre

One of the best MOOCs I followed was Barbara Oakley's Learning how to Learn. In a Talk at Google, she summarized her research and mentioned memorization as a positive thing. Here's the video at 45:15 when she explains it https://youtu.be/vd2dtkMINIw?feature=shared&t=2714

I'm trying to figure out now the best way to supplement my Odin Project learning with tests that are at the same skill level.

Collapse
 
sergionr profile image
Sergio N

Good lord! Created the dev.to just to share my sincerest gratefulness

In my head i kept wondering if i was failing since i keep not-remembering some methods and having to look back at documentation

thank you!

Collapse
 
as_wittwer profile image
alex

I graduated college with a b.a. in mathematics and statistics back in 2020; I think the last time I did a partial differential equation was sometime in 2017.

fast forward to today, and i panicked because I couldn't tell you how to do a differential equation, what df/dx of sin(x) was, or even what l'hopital's rule did. But that didn't mean I didn't know how to do it.

See, when you learn things, you dont need to memorize it. You just have to do it. You don't have to memorize how to push pedals on a bike; if its been a few years you can still get on a bike and ride it.

The key is getting back on the bike.

See, I didn't know how to do those things, but I was able to figure them all out within minutes after google searching or reading something about it. Thats how memory works, and how developing skills works, versus rote memorization of formulas, algorithms, etc. If you understand the how and the why of something, you don't really need to know the exact details.

Take for example, your favorite book or movie. Do you remember every line of The Princess Bride? No, but you remember that one can never beat a sicilian in a game of chance when life is on the line. So you work from there. You remember the poison, but not the type. Etc etc. It comes back, and you have all the structures for relearning it there.

I guarantee you that nobody knows it all. If they do, they're lying. You just need to do it. You just need to get back on the bike.

Collapse
 
ojimcy profile image
Ademu Emmanuel

This is supper encouraging. I used to think I'm dumb.
Thanks for sharing. Long love chat gpt 😂

Collapse
 
princemuel profile image
Prince Muel

💯 me. Anytime I learn something new, or encounter something useful, I ask myself... "in what situation would I need this?". Once, I have my answer, I'm free to make a mental note for the use case then forget about it until run into a situation where I need it. This has never failed me...yet 😁

Collapse
 
icandoallthingthroughchrist profile image
ICanDoAllThingThroughChrist

This is exactly how I feel👍. Well written

Collapse
 
iromata92 profile image
Yagmus Inyagham

Thank you...this write-up has really encouraged me.

Collapse
 
blehnk profile image
Ashish Nath

Thanks for helping me calm down :)

Collapse
 
olivia73code profile image
Olivia73-code

This was great to read, thank you. I am at the very beginning stages of learning (HTML) and I have often wondered how I will remember everything. However, I am good at making notes and have been able to understand the documentation I have read when a point needs further clarification. Thank you for sharing!

Collapse
 
kino6052 profile image
Kirill Novik

The most important thing in learning is understanding of concepts. That's why some students like STEM subjects, is because if you understand, you don't need to memorize