Small Victories

Celebrating the small things as I learn JavaScript.

Image from Unsplash.
Learning to code is teaching your brain a whole new way of thinking.

I can’t remember who said it or how many times I’ve been told this but I would agree. Learning to code is teaching your mind a new way to problem solve. Giving your brain a new lens through which to view the world.

Admittedly, it’s easier for some than others. A fact I know all too well after working with a developer who could learn and understand code just by reading about it. None of that practice makes perfect stuff. For him, all it took was reading and voila!

I wish I could say the same for me.

While I am a quick learner, I also know I learn best by doing. Repetition helps me soak up and expand on what I’m learning; my brain cementing in the pathway for this bit of knowledge I just acquired. But if I let too much time pass between when learning something to actually using it, the pathway dries up. The knowledge isn’t gone — far from it — I just can’t access it.

Which is exactly what happened my first time through Unit 1 in the Full-Stack JavaScript Techdegree.

Most of the first week, I dedicated four to five hours a day to learning to code. Things were going well for a few days and then I started to struggle when functions were introduced. From there, things compounded.

I could easily complete the quizzes and do the short coding challenges because Treehouse would prompt me about an error, but when it came to the larger, self-directed challenges, I got stuck.

Eventually, I’d give up on the challenges and move on to the next video. I’d follow along with Dave and everything he said made sense. As I watched him type, I could explain exactly why he was doing X, Y, or Z. The problem wasn’t in understanding what the code did. Rather, it was in assembling it.

Like putting together a puzzle, I’d been able to assemble bits and pieces. I could get a few things to work independently and jointly, assembling smaller parts of the puzzle and occasionally combining them to get bigger pieces. All I had left to do was connect the pieces. But I couldn’t.

That, combined with an unanticipated break, made things even harder when I came back a week later. In my mind, I wasn’t completely ready to start but I figured once I’d settled in, I could put a few pieces together and then work out the rest. I figured, if I just got started, it would slowly come together.

It didn’t.

So, after combing the internet for famous quotes from women and fumbling around in Atom for a few hours, I stopped. I deleted my GitHub repository and the project files on my laptop with the intention of starting over come Monday.

Which is what I did. I went back to the drawing board and went through Unit 1 again. I rewatched every video, retook every quiz. I redid all of the short coding challenges.

I even redid the longer coding challenges. Treehouse saves each workspace so when I returned to them, all my previous worked was saved, but I deleted all my past code and started fresh. As I type this, I’m nearing the end of the lesson on arrays so I haven’t completely gone through everything yet but, I’ve already seen tremendous progress.

It was most noticeable when I got to the color block challenge. I had to use a function and a for loop to print 10 circles that change color each time the page is loaded. The first time around, I wasn’t able to do it. The second time, though?

I nailed it.

As I’ve progressed this time, I can feel things falling into place. I can feel my brain working through the scenarios Dave describes in each video, thinking about how if I were working on a shopping cart or list program, I’d go about solving it. I can see the code in my mind and how I’d lay it out.

When the small code challenges come up, I’ll do what Dave asks and then, think of a way I can improve it. If I’ve repeated a line, I’ll refactor and use a loop or work a function into my code. If I’m working with strings, I’ll think about how I’ll have to change the code to work with numbers.

Though these may not be huge for other people, these are all victories for me. Just a few weeks ago, I was unable to complete all the challenges I tried. Now, within a few minutes, I can not only solve whatever challenge is laid out, but I can challenge myself, too.