How To Learn Programming

Authors
  • avatar
    Name
    Austin Howard
Updated on
programmer struggle face

You’re never going to learn programming by watching a video called ‘learn programming’. The only way to learn programming, and everyone who I’ve ever met who can program well learned it all in the same way. They had something they wanted to do, and then they tried to do it. Then they were like, ‘oh it would be nice if the computer could do this thing’, and that’s how you learn, you just keep pushing on a project. The only advice I have for learning programming is - go program. - geohotz

Start with a problem

Here’s a problem.

I struggle with procrastination. When I force myself to ‘just start’, after the first 10 minutes, all of the sudden I’m in a flow state and the procrastination is gone. How can I use a computer to help me overcome this problem?

Solve the problem with minimum functionality

Commit yourself to solving this problem.

Here’s a potential solution to that problem.

Build yourself a mobile app. There are many ways to build mobile apps - part of this is just finding one framework to do this with. A google search will give you many different platforms / frameworks / languages by which to do this. Just pick one - React Native for example.

Have the app send you a push notification every morning reminding you that procrastination is just your limbic system playing games with you. You have a prefrontal cortex, you’re better than that. You can self-reflect. Go get a yerba mate and start for 10 minutes.

Evaluate the error rate of your solution

Solving solutions with computers usually involves creating some kind of feedback loop. Have the app send you a notification at the end of the day which could be like a form that you fill out that has things like, rate yourself from 1-10 on how well you did on overcoming procrastination. Maybe there’s a text box where you write what problems you solved that day. Store these things in a database. A google search will give you a bunch of database options - Supabase for example.

Now you have access to a history of self-evaluation that you can evaluate how well your solution is working.

Make the program better

Now that you have a feedback loop, you can start making the program better. If you’re regressing over time, probably a new feature that tells you how bad you’ve failed to overcome procrastination for the past week would help you improve.

You now also have a history of all the small things you’ve accomplished overtime. Do you remember all the small wins you have over the past 20 years? No. This data is valuable, you could probably do something special with it.

Get users

Allow other users to create their own accounts through an auth provider like (sign in with your google account) or something like it.

That database you have would now need to support storing any user’s data. Things get interesting now but this is just another problem to solve.

If you’re lost, do this first

Make a codecademy account.

Pick any language and go through the course.

Understand:

  • Variables
  • Data types
    • Strings
    • Booleans
    • Integers
    • Floats
    • Arrays
    • Etc…
  • Conditional statements
    • If, elseif, else, etc.
    • Switch statements
  • Functions
  • Classes
  • Loops
  • Control flow (the order in which a program runs)

By understanding these basic concepts, they will transfer to all languages. After learning these concepts, learning new languages becomes easier and easier.

After this you could go through a more general course like “web development” or “data science”. Maybe even the “iOS Developer” one would help getting started on solving the procrastination problem.

Eventually do the “Computer Science” course. Then watch a harvard / mit free online CS 50/101 courses. Learning the fundamentals of computer science will make you a deadly weapon. Not required to start though.

Understanding basic math, linear algebra and discrete math will take you a long way.

Last thing

This is a marathon, not a sprint. Ultimately this is no different from exercising, the more you put in the more you get out. The more things you build, the more credit you have - the more proof you have that you can convince someone else to give you money to solve problems.

Oh, and learn Git. Make a Github account so that you can keep all of your programs there. Git will let you control and version your program - and it allows other people to work on your program. Learning Git is essential.

Codecademy has a good Git & Github course.

In general, spend the minimum possible time on courses / tutorials that you can. Banging your head against solving a problem will get you astronomically further.

A good video to watch is George Hotz | Programming | what is programming? (noob lessons!) | Science & Technology. Try to take what he says for what it is, and don't anything personal.