How I Am Learning Programming

At Launch School

Antoine Leclercq
Launch School
5 min readFeb 1, 2017

--

As stated in my previous post, this story is going to be about my learning methodology, how I changed it in order to perfect it.

When I was in High School and during my Bachelor’s degree in Economics/Data Mining — my learning methodology wasn’t so good. It was getting me good grades but it was not longterm oriented. I used to just cram (cram, cram, cram…), it was almost all I was doing except for projects or assignments that would take a while to complete. As long as I had good grades, I was feeling accomplished and like I had learned something.

When I started Launch School, my perspective was not so different. I knew I was getting into some “mastery-based learning”, but I thought the program would take care of making my learning “mastery-based”. I thought I would not have to do anything special on my end — except for following the program diligently. I learned the hard way that it was not the right approach. Simply going through the program was not enough. I realized I needed to be proactive in my learning, and this doesn’t mean to just type along during exercises/examples. It means actively learning the content and actively reviewing the learned content — so it doesn’t fade away.

In my previous post, I talked about how I forgot about 80% of what I had learned in the backend part of Launch School’s program. Once I realized this nightmare, I decided to dedicate two to three months of my time to learning how to learn and finding my own methodology in order to become a good learner. My objective was to be able to keep moving forward in Launch School’s program and learn the new concepts the right way while reviewing the learned ones the right way. It was hard. It took me quite some time to finally come up with a working system. I am still tweaking and perfecting it but it is providing results that I can already see.

My Mastery-Based Learning Methodology

# Learning New Material

When going through some new material, I now take my time in order to make sure I understand the new concepts. To verify my understanding, I try to explain the concept in my own words — out loud or in my head. I also try to find an analogy for the concept in order to make it concrete and connect it to something I already know. If possible, I also try to include the new concept in the mental model I have of the higher-level concepts, in other words, I try to fit the pieces together.

Once I feel like I understand the concept well, I put it in one or multiple flashcards. There’s a whole lot of science about how to make flashcards. For me, it’s about capturing my understanding. I try to use keywords rather than phrases and I try to make my flashcards answers short, without too many elements. So when the concept requires a lot of understanding/explanation, I usually create multiple flashcards by breaking my understanding into different parts.

After creating flashcards, comes practice. In Launch School there usually are some exercises and/or projects to practice your understanding of a new concept. I don’t tend to go out of my way to build additional projects — unless I feel like it’s needed — because there already is a massive amount of content within the Launch School program with a lot of exercises and projects to build.

Finally, I edit or create flashcards in case the practice phase refined or deepened my understanding of the new concept.

# Reviewing Learned Material

Two words: flashcards and practice.

Flashcards are great because they use the concept of spaced repetition which is optimal since it forces you to review right when you’re about to forget.

Practice helps you solidify your understanding and make sure that you are still able to apply the concepts you’ve learned. Practice can come in different forms:

  • exercises
  • projects
  • asking yourself low-level questions when going through new, high-level, material

## Exercises

For exercises, I simply go through code challenges in Ruby/JavaScript/SQL in order to review and practice my problem solving skills along with my language fluency.

## Projects And Asking Yourself Questions

When I build new projects — in the context of Launch School — using learned concepts (whether they were freshly learned or learned a while ago) I try to ask myself the right questions. What does that mean? It means that when there is a new high-level concept that is used in a project, I try to break it down into some lower level concepts that I learned before.

A good example for this are frameworks/libraries. Let’s take jQuery. jQuery is a JavaScript library wrapping browser support in universal methods. If we take the following code:

$('a').on('click', function(event) { // code });

What is happening here? First of all, $ is simply a JavaScript function defined inside the jQuery library. In our case it takes a string — containing a CSS selector — as an argument. This returns a jQuery object — which is a JavaScript object — containing all the a elements present inside the DOM tree. Then it registers an event listener for the click event on each element contained by the jQuery object. How does jQuery do that? We can easily do the same thing with plain JavaScript and the DOM/BOM APIs:

var aElements = document.querySelectorAll('a');for (var i = 0; i < aElements.length; i++) {
aElements[i].addEventListener('click', function (event) {
// code
});
}

Once you know what’s happening under the hood you can appreciate jQuery’s simplicity and understand how it works. If you want to dig deeper you can now explain how your plain JavaScript code works, which will force you to review more core concepts. Let's demonstrate:

  • the Document interface defines the querySelectorAll method which makes it accessible to Document objects, such as window.document
  • querySelectorAll returns a NodeList object, which is an Array-like object
  • the NodeList interface provides us with the property length and the method item defined on the NodeList interface
  • some JavaScript magic allows us to use the operator [] on the NodeList object, but what’s really happening is that the method item is being called with the argument i
  • each element in aElements is an HTMLAnchorElement object and the HTMLAnchorElement interface inherits from HTMLElement , which inherits from Element , which inherits from EventTarget , which defines the addEventListener method used on each element in our for loop
  • the addEventListener registers an event listener —a callback function, the second argument in our example — on each element which will be triggered by an event of type click during the targeting or bubbling phase

I could go into how asynchronous callbacks work and more, but I think I’ve made my point. As you can see, just one line of code in jQuery gives us the opportunity to review a whole lot of core concepts.

Final words

At Launch School, the approach is “mastery-based learning”. In my opinion, if you want to be able to use this approach you first need to master how to learn, and have your own — working and tested — learning methodology.

I hope this post will give you some insights on how to perfect your own learning methodology. Happy coding!

--

--