Learn to code (or do anything): top down, bottom up and other approaches

Learning to code is hard. Software engineering, the field we most commonly refer to when talking about ‘learning to code’, is based upon a foundation of computer science and applied mathematics. And while it is true that you don’t need to be a mathematician or a computer scientist in order to be a software engineer, the another truth is that learning even basic programming concepts is hard for most people. In this article we will explore a little bit of learning theory, and how we can apply it to those just getting started with learning how to code. I’ll lay out some of the advantages and disadvantages of concepts like the bottom up versus top down approaches to learning, as well as some alternatives that are worth considering. This content is aimed at newer programmers, but these concepts are applicable to anyone who is interested in learning more effectively, even if the topic isn’t programming.

I’ve been a professional programmer for over 7 years, and I started messing around with code way earlier. If there’s one thing that I can say confidently about this profession, it’s that the learning never stops, and it never gets any easier. Every time you master a difficult concept, you can be sure that another one is right around the corner. I spent a lot of my time early on reading obsessively about programming topics, mostly in the form of what shiny new framework was better than the old solution to the problem. I read about topics like whether or not I should use jQuery or MooTools for my next website project. Frequently felt way out of my depth, like there was no way I could possibly understand any significant part of the web development ecosystem (and this was before the explosion of front-end solutions). Thankfully for you, people like me exist, with just enough perspective to help you steer clear of pitfalls and time sinks that won’t help you effectively level up as a programmer.

So let’s dive right into it.

The concepts of top down and bottom up processing have been applied to a number of disciplines, but the one we’re most interested in is how top down and bottom up can be applied to learning. The general definition of top down learning is a process that immerses the learner in the full context of the subject matter. Put another way: if you were someone who was interested in learning how to swim, and I was someone interested in employing the top down method, I’d throw you in to the pool. Conversely, the bottom up approach involves a process that is much more granular and theoretical. A bottom up approach to learning involves exposing the learner to the fundamental concepts of a subject matter in isolation. A bottom up approach to learning to swim would involve learning about fluid dynamics, anatomy and physics, but would not involve a pool.

The bottom up process of learning/teaching involves exposure to only the component parts of a particular subject matter, and slowly builds upon those components towards the whole. Learners using this approach only move on to the next component once the previous, prerequisite components have been mastered. For the most part, traditional public education (at least in the US) employs this approach.

The bottom up approach enjoys a number of advantages. What I consider primary among them is that the learner is able to acquire a complete understanding of the subject, as long as they take the time to master each component part. Bottom up is also easy to structure: breaking a problem down into small, coherent fragments lends itself to organization. A teacher planning a bottom up approach to a curriculum already has to organize their material into small topics. In the world of programming, understanding a significant portion of any language, framework, or tooling is a long and difficult process. When learning a new language, a bottom up approach is useful for learners that need to understand a concept at a high level in order to feel confident about moving on to another concept. For example, learning the basics of JavaScript using a bottom up approach might involve learning about primitive values like Numbers, Strings, Booleans, Arrays, and null/undefined, then moving on to Objects and Functions, before finally moving on to scoping and control flow. Ideally each concept would build on top of the previous concepts to create a nice progression.

The most obvious disadvantage to the bottom up approach is that a learner employing this method will lack any sort of useful context about the concepts they are learning about. This isolation leads to an inability to apply the learned concepts in any kind of meaningful way. If we return to the swimming example for a moment, it seems like common sense that no matter how much you learn about fluid dynamics, anatomy, and physics, if you never actually try to swim, then it follows that you won’t ever really be a good swimmer. This is also why you’ll almost never see any type of (good) modern programming resource that doesn’t include at least some type of practical portion.

Top down

A top down approach to learning embraces a macro-oriented, practical process that has the learner immersed in the subject matter. The priority for a top down approach is to provide a wider perspective of a problem or subject area, without necessarily going into detail about how specific components work together. A great example of top down learning applied to programming would be a situation where a new developer was given a project they needed to complete using an unfamiliar language or toolset. Instead of relying on a progression of mastery of isolated components, a top down approach instead lets the learner understand the individual parts by exploring and experimenting.

Advantages of top down

A top down approach to learning is particularly advantageous for some programming students because getting a chance to see how everything is working together is exciting. Personally, my interest in programming was sparked and maintained by resources that let me implement my own complete, (mostly) working projects. Initially this was messing around with making command line quizzes and adding functionality to games via scripts, but the common denominator here is that I probably wouldn’t have even bothered if the only way to learn was one step at a time. Besides providing an incentive to learn, a top down approach is practical. For many learners, the goal is to learn only what’s necessary to understand or implement a very specific concept. In this situation, a bottom up process would be overkill, and possibly even a waste of time.

Disadvantages of top down

Top down learning also comes with disadvantages. Generally, top down learning leaves the details to the student, which many times can result in a patchy understanding of a concept. Learners may grasp enough to just “get it to work”, with no motivation or clear path to understanding how the foundational components are working together. When I was writing my first command line quizzes, I had no understanding of the differences between primitive values like Strings and Numbers, so I was quite perplexed when statements like 1 + "1" resulted in 11.

Although both the top down and bottom up approaches have their own merits, I believe that like many things, a simple dichotomy doesn’t represent all of the viable options. It’s a little cliché to say, but I really do think the best approach lies somewhere in the middle.

In my experience, there are two types of situations that almost never work out when trying to learn a new programming concept:

Some of you have probably already been here. You get excited to learn about the latest and greatest in Single Page Apps/Machine Learning/Augmented Reality/Blockchain Game Development, so you dive right in to a 32-part YouTube series on how to build your own. By video 4, you’ve entered territory you didn’t even know existed, and convinced yourself you must be the worst developer ever. This is not a productive way to learn, and it showcases some of the nasty downsides of a top down process. Put another way, sometimes total immersion and full context can be overwhelming.

In my experience, ‘the lengthy tutorial’ almost always leads to the other of the two bad learning situations: the comprehensive resource. After you’ve convinced yourself that you don’t know enough to make your great new idea, the only feasible solution is to find the most comprehensive resource available on the subject, and try and slog through it in order to better understand the subject and ultimately build your Single Page App/Machine Learning Algorithm/Augmented Reality Thing/Blockchain Game. However, the comprehensive resource isn’t exciting, and so after the first few chapters you put it down and then never again revisit the subject. This is a great example of how bottom up learning can let you down. Simply put, sometimes the regimented, step-by-step process can be a boring way to learn things.

Build small things every day

I think the solution comes in two parts. First, learning a new programming concept should involve coming up with the smallest possible practical application of that concept. For a developer trying to learn a new language, this might be a command line ‘choose your own adventure’, or an implementation of a simple game in the browser. Once you have a small, achievable goal in mind, learn the bare minimum of what you need to in order to implement that application, but work to master those concepts. If I’m building a ‘choose your own adventure’, then I’ll probably really need to dig in to standard inputs, standard outputs, and simple control flow in the language I’m learning. Ideally, these types of small projects will be something you can complete in a day. That way, you never struggle for too long on a concept, and you continually will incentivize yourself to come up with new projects by the small successes you make on a shorter timeline.

Wrapping up

In this article, we explored the concepts of the top down and bottom up approaches to learning/teaching. We also touched on the idea of building small things frequently, in order to navigate around the pitfalls of high complexity and boredom to keep you excited about learning new things.

If you found this article helpful, please consider sharing it with others. If you didn’t, I’d love to know why, and maybe hear your thoughts on what other processes should be considered when learning on your own.

Austin Tindle

Build a simple chat app with node.js and socket.io

To develop a real chat application, we have to put in place a real-time system of sending/receiving data. It will be impossible to do it with a relational database and Ajax calls. Thank’s to WebSocket and the library socket.io, it becomes easy.

You can follow this tutorial with my repo Github: https://github.com/ngrt/simpleChatApp

Technical stack

Here is the technical stack that you are using for this app :

WebSockets and socket.io

WebSockets is a protocol that allows a bilateral synchronous exchange between a client and a server.

In the classic web, a client requests to a server and a server responds sending it back the data. This system is impossible for a chat app.

In WebSockets, the server can send data to the client, but the client can too ! A WebSocket is a kind of communication pipe opened in two directions.

Socket.io is a library based on this protocol to make the use of WebSockets easier.

The Javascript mafia

Node.js is a Javascript back-end technology executed by the server as PHP, Ruby or Python. JavaScript uses events. Node.js keeps this particularity so it is easy to make asynchronous code.

Node.js comes with its own package manager: npm. It becomes easy to install, update, delete packages.

In this tutorial, we are going to use express.js. It’s a micro web framework based on node.js.

Set up of the development environnement

First of all, we need to configure our development environment.

The first thing to do is to start npm, our packages manager. To do so, open a new terminal, create a new repository which will contain our project, go in it and initialize npm:

$ mkdir createSimpleApp
$ cd createSimpleApp
$ npm init

npm will ask you for several information. If you want to skip that, press enter until the end. Now if you look at your project, we will find a new file : package.json. This file is listing all your dependencies.

So now, we are ready to install the packages needed to develop our chat app! We are going to need these packages:

  • express: the micro web application framework for node.js
  • Nodemon: a package that will detect any changes and restart our server. We will use it instead of the classic node command.
  • ejs: a template engine to simplify the production of HTML
  • socket.io: the famous package than manage WebSockets

To install them on our environment, it is super easy:

$ npm install --save package_name

I let you do the work for our 4 packages.

In your package.json, you could add this line into your scripts key:

“start”: “nodemon app”

With this line, you will be able to launch your app only with one commande using nodemon:

$ npm run start

Our environment is set up, we are ready to develop our application.

The chat app

Architecture of the app

First of all, we have to separate to part in the development of an application: the client part and the server part. We will have to develop the two parts to make our application up and running.

The server will be handled by node.js to make all the engineering (launch the packages and the website). This code will not be seen by the client.

The client part will be loaded on the computer of the client. He will have direct access to the files (html/css and js).

Server side:

We have to create the file app.js that will launch our server and all the packages.

This bunch of code is actually initializing our express app. If you go to http://localhost:3000, you will see a gentle message.

Now we just need to configure socket.io to be ready to deep dive into the WebSocket world.

Here, the io object will give us access to the socket.io library. io object is now listening to each connection to our app. Each time a new user is connecting, it will print out “New user connected” in our console.

If you try to reload our browser on localhost, nothing happened… Why ? Because our client side is not yet ready.

For the moment socket.io is only installed on the server part. Next, we will do the same work on the client side.

Client side

We just have to change a line in our app.js. In fact, we don’t want to display a « Hello world » message, but a really window with a chat box, inputs to write username/message and a send button. To do that we have to render an html file (which will be in our case an ejs file) when accessing the “/” root.

So you need to apply the render method to the res object.

In the other side, you will have to create a views folder, with an index.ejs file in it. The css will be in a public folder:

Our localhost:3000 will look like this :

So now that we have our basic template, we have to « install » socket.io on each client which will attempt to connect to our server. To do that, we have to import the socket.io library on the client side:

<script src=”https://cdnjs.cloudflare.com/ajax/libs/socket.io/2.0.4/socket.io.js"></script>

The only way to work with socket.io is in a .js file. So at the end of your body add these lines:

<script src=”http://code.jquery.com/jquery-latest.min.js"></script>
<script src=”chat.js”></script>

And create a chat.js file in the public folder.

For the moment, just write this in it :

As you probably guessed, when the client will load this file, it will automatically connect and so create a new socket.

So when you refresh the page, we will see « New user connected » in your terminal.

Send and receive data


When a user connects to our application, we will set him/her a default username, for example “anonymous”. To do that we have to go on the server side (app.js) and add a key to the socket. Actually, socket represent each client connected to our server.

We also will listen to any call made in « change_username ». If a message is sent to this event, the username will be changed.

On the client side, the goal is to do the opposite. Each time the button change username is clicked, the client will send an event with the new value.


For the messages, it is the same principle!



For the new_message event, you can see that we call the sockets property of io. It represents all the sockets connected. So this line will actually send a message to all the sockets. We want that to show a message sent by a user to all (and itself included).

Here is the final result of our chat app:

Little improvement

We can add a quick improvement to make our application more realistic. We will add the « XXX is typing… » message.

To do so, it is very easy.

After adding an HTML element in our index.ejs, we just add a jQuery event listener on typing and send a socket event named typing.

On the other side, we listen to typing and we broadcast a message. Broadcasting means sending a message to everyone else except for the socket that starts it.


See, this application is really easy to code. Before knowing the existence of WebSockets and socket.io, I thought this kind of application was really hard to code !

To improve this app, here is a list of functionalities to add:

  • A registration system with the possibility to chat in a one-to-one chatroom
  • History of all the conversations
  • Online/offline labels
  • Copy every features of WhatsApp !

Noufel Gouirhate

What the different credit scores mean

As a general rule, here’s how scores are viewed

Below 580: Very High Risk

Anyone with a score below 580 will be viewed as a very high risk with a high likelihood of not honouring the debt. As such, many companies will not consider them at all. Those that do will probably require a substantial deposit and/or collateral. They will also charge you more in terms of interest as a result of the increased risk they are accepting.

581 – 599: High Risk

This is a borderline area where lenders will tread very carefully as you will be seen as a high-risk client. Finance and credit will be extremely difficult, but not impossible, and when granted, will likely come with conditions and high interest rates.

600 – 619: Average Risk

A score in this range is considered to be an average credit risk and you should not have much difficulty getting reasonable credit with fair interest rates if you do not have any judgements or listings behind your name.

620 – 649: Low Risk

At this level, things are looking up and the institution will look very favourably at your application. They will want to do business with you as you have proved you are a responsible user of credit and therefore pose a low risk to them. They are likely to offer you an attractive deal and you will have a strong negotiating position. Use it.

650+: Minimum Risk

With scores this high you are in a great position to negotiate finance and you should qualify for preferential terms and interest rates. Companies want to lend money to people with a score over 750 and will go out of their way to get your business.

As you can see, often just a few points can make a significant difference. Moving up a score bracket will be beneficial so do everything in your power to improve your score. An improvement of 10 or 20 points is not a major challenge with a bit of insight and effort.

There are obviously other factors that are taken into consideration but your credit score is one of the most important. Do everything in your power to maintain a good score or work hard to improve a poor score. With a low score, you will be going cap in hand to the lender whereas a higher score will put you in a position of strength and give you much greater power when negotiating the terms of the loan.

You can view your credit record for free credit score and DirectAxis Pluse websites in order to know your credit standing.

5 Ways to Increase Your Credit Score

Is a low credit score holding you back from getting approved for a loan? Do you dream of becoming a homeowner, but need to improve your Credit score?

We’ve got you covered! Follow along for 5 ways you can increase your chances of approval once and for all.

Low Utilization Makes a High Credit Score

Your credit card utilization is a measurement of how much of your credit card balances you’ve spent versus your overall credit limit. This counts for all your cards individually and combined.

If you have a credit card where you’ve only utilized 10% of your balance and another where you’ve utilized 70% the 70% utilization will still have a negative impact. Opening a new credit account to offset the high utilization on another card isn’t a smart move either.

In the meantime, other tips to keep your utilization down include:

  • Making small payments throughout the month
  • Spread charges across multiple credit card accounts.
  • Ask for a limit increase don’t overspend to match your new credit limit

It’s important to remember to keep your balance at 30% of your credit limit or less. If you need to make a large payment using a credit card, try to pay the purchase off as soon as possible.

Pay Off Old Collection Accounts

Resolving accounts that had been transferred to a collection’s agency will drastically increase your credit score. When you check your credit report, you will have a list of these accounts that are in bad standing.

Since the agency’s contact information is typically listed on the same page, you shouldn’t have too much trouble finding someone to assist you. If the balance that needs to be collected is more than you can afford during the time of the call, the representative you speak with may ask if you’re interested in settling the account.

When you’re settling an account, you are usually being asked to pay the principal balance which is the amount that was owed before the account became past due. This means your late fees and interest have been waived.

There’ll be a due date for the settlement amount (usually 90 days out.) And most collections agencies will allow you to divide those payments into manageable installments as long as the last one is by the agreed upon date.

Be mindful that settled accounts may still show on your credit score as not having been paid in full, even after your last payment. Before agreeing to a creditor’s settlement terms, ask if it will show as paid in full on your credit report.

Depending on their answer, you might be better off making payment arrangements for the full balance instead of settling. Most agencies will work with you to set up payments according to your pay schedule.

Build Credit with a Secured Card

The beautiful thing about secured credit cards is they are built to help improve your credit score. So, if you’re young and haven’t established credit yet or you’ve made mistakes that caused a low score, a secured card can help.

The process of signing up for a secured credit card is fairly similar to signing up for a normal card. You will still need to provide information like your social security card, address, and salary.

Your credit limit will be determined by the deposit amount you choose. Different credit card companies have their own rules and qualifications, so make sure you do your research on the minimum balance requirements and APR.

If you’d like to start off with a $200 limit, for example, that amount will be deducted from your bank account and you can swipe your card up to that amount. Although, you need to be mindful of the utilization.

When you’re searching for a secured credit card, find one that will reward good behavior. For example, with Capital One’s Platinum card, you will receive an automatic balance increase after having made 5 consecutive payments on time.

Your payments and utilization will be reported to all the major credit reporting agencies. If you manage the card correctly, you’ll see your Credit score increase a little every month.

Don’t Close Old Accounts

There isn’t much you can do about your credit age, but this factor has a huge impact on your credit score. A credit age of 5 years or more is usually considered good.

This means you’ve had open credit accounts and have been making payments for at least 5 years. If your credit age is less, you will have to be patient while it increases.

While you wait, don’t rush to open several lines of credit. It has a negative impact on your score when there are a lot of requests in a short period.

Also, don’t close existing lines of credit. This can be an old credit card you paid in full and no longer use.

You’re better off storing the card in a safe place and forgetting about it for a couple of reasons. Let’s say that credit card has a R1,000 limit. Since you aren’t using it, it has a R0 balance being carried from month to month. That 0% utilization is adding points to your credit score.

If you’re using a different card and keeping it in good standing, that unused card will still help when you apply for a loan or another line of credit. Also, keep in mind that even an account closed while it’s in good standing will sit on your credit report for up to 10 years.

Protect Your Identity

With the majority of us paying bills and making purchases online, the risks for identity and credit theft are higher than ever. Protect yourself and your credit score by monitoring and then reporting suspicious transactions and accounts.

This includes disputing accounts on your credit report that shouldn’t be there. Consider signing up for an identity theft protection service. Many banks offer them to account holders and they’re inexpensive. If your name is ever used, it can take years to repair your credit.

Microsoft Issues Windows 10 Upgrade Storage Warning


Microsoft program manager Jesse Rajwan confirmed in a blog post, that the company is taking measures to ensure Windows 10 computers will always be able to upgrade automatically. And you might not like it.

Microsoft is introducing ‘Reserved Storage’ with Windows 10 Build 1903. This will consume a lump of storage from your hard drive which “cannot be removed from the OS” and ensures your computer can receive the latest upgrade.

Rajwan says the typical amount taken from Windows 10 users’ hard drives will be 7GB: “This will enable most PCs to download and install an update without having to free up any of your disk space, even when you have minimal free disk space.”

All of which would be good news, except Windows 10 updates have been a dangerous mess for some time.

What’s more, it’s hard to see how Reserved Storage helps. Those with fast, modern PCs will always have more than enough storage space to never need it and those with older, slower PCs with very limited disk space will a) not want to give up 7GB, and b) be those most cautious about giving Windows 10 new ways to update itself whenever it wants.

How Windows 10 Reserved Storage will show up in user settingsMICROSOFT

That said, Microsoft states it will initially only apply Reserved Storage to new PCs which ship with Windows 10 1903 or later. But be warned, Microsoft is repeatedly replying to user questions with “At this time” which suggests a wider roll-out of Reserved Storage is coming.

For that to happen, however, Microsoft must surely improve the stability of Windows 10 updates. Even fan sites have written about Microsoft having a “Software Quality Problem” and, in 2018 alone, Windows 10 upgrades caused serious problems in JanuaryAprilOctober and November.