A lot of people who don’t code ask me questions like, “Why should I learn to code?”, “Is it easy to become a programmer?”, “I’ve never coded before, but do you think if I study for a month or so I can become a web developer?”.
Usually my first response to any of these questions is to just laugh, and then say “It’s not that easy, you really do need to study a lot more than you think. But that said, you should learn to code because you might need it some day like you need basic math.”
Math is pretty important because we need to know how much we have of something, especially how much money, or how much time we have to do an activity.
With programming, the question isn’t how much, but how optimal can we do some task, (or series of tasks).
You have tasks every day that you have to do. Most of these tasks are often dictated by your own longer term strategy on how you want to live your life, while some tasks are dictated to you by superiors, family members, heck even your kids if you have any!
The dictation part is what you want to focus on if you are a programmer. People will tell you to do all kinds of things:
- Wife: Wash the dishes and take out the trash tonight, please!
- Child: I want to watch Peppa Pig! Change the channel!
- You: I want to study more this week.
- Parent: When are you going to call us?
- Boss: Hey I need changes to this website by the end of the day.
Take a moment right now, and think — how would you organize these tasks?
Again, programming is efficiency, organization, being optimal. How would you prioritize these tasks?
Next, you would need to ask yourself — was that prioritization the best I could do?
To know for sure, you would need to dive into each task manually, and go through it step by step. Maybe there are some more steps to that task than you realize.
Wash the dishes and take out the trash tonight, please!
On the surface this sounds simple. But how would YOU ACTUALLY DO IT? Let’s look at the steps involved for one scenario:
- Get up from wherever you are (if you are on couch)
- Walk over to the dishes
- Get the dishwashing soap, sponge, put soap on sponge
- Turn the water on, to mid hot (check by testing with your hand, if not burned good)
- Rinse the dirty area of dishes, then turn off water (to not waste)
- Start picking up dishes, lather and scrub with soap on the sponge
- Rinse each dish out after all soaped with mid hot water
- Put washed dishes into other side of sink area, designated clean area
- Keep going until all dishes have moved from dirty area to clean area.
- Wash out soap from your hands then wipe them with a towel
- Go to trash, pull up the trash bag slightly and tie the bag closed with a trash tie
- Make sure bag is completely sealed
- Be careful not to get trash on yourself as you pick up the bag from the bin.
- Walk over to dumpster then toss your trash
- Wash your hands again with soap, rinse and dry them with a towel
There are about 15 steps in that exercise. As you glance over all of these steps, do you see any redundancy? Are there steps that were unnecessary and could be re-ordered or removed? How about some tricks you know personally to speed up this process? Can you add them to this task without adding more work for yourself (ideally reduce steps)?
I thought about my own washing the dishes the other day and I realized — I don’t want to always wash dishes, especially given it can take me as long as 20 minutes to do a huge load. Compound that with throwing out the trash and I realized I’d be wasting 30 minutes of my life to this boring task DAILY.
We have a dishwasher at our house, and THANK GOD for that. Yet the dishwasher isn’t always the best option especially when you have dishes that aren’t meant for the dishwasher. (This is why now I buy only cups and plates that can go in a dishwasher lol).
So I can potentially use the dishwasher to reduce some of my workload — but not all of it. I’m still going to have to wash some dishes, pans and pots.
Hence I came up with an efficiency model for this task:
First, throw the trash out because my hands will get dirty regardless and I’ll have to wash them again anyway. Why do this twice?
After that’s done, I come back to the dish area and wash my hands with soap. Now I can begin washing dishes. Still I don’t want to wash everything, so I begin separating what the dishwasher can do and what I can do into piles. The dishes that the dishwasher can do get rinsed and put in the dishwasher for later. The pots/pans, ceramic cups I have to do get put to the side to do in a moment.
Usually after this separation, I’m able to reduce my workload down to 5 minutes, with the garbage also being 5 minutes. I can let the dishwasher run on its own and expect clean dishes after an hour (while I go do something else with my time — e.g. call the parents). So I’m done in 10 minutes — which is pretty good, and I get time back to myself!
I can optimize further by choosing not to throw the garbage every day unless it’s FULL or it’s got SMELLY BAD food that needs to be disposed of or roaches will come. So because a majority of my food waste is just plastic or paper (which can be recycled instead), I’m good with throwing out the trash less frequently. That said, I still have to do it at least a few times a week.
But if we amortize the time (think best case scenario) involved with throwing out the trash, most of the time it’s a non-task, meaning I can do just the dishes for 5 minutes on most days, with an occasional up to 5 minutes more of work time a few times a week. Not bad, from 30 min to 5 min a day! Isn’t being. a programmer cool? Don’t you feel like you already saved your own life from years of wasting hours on doing dishes and throwing out the trash?
Getting the idea now?
It’s all about efficiency, and I’m sure if you view the workflow I wrote out above and optimize, you can probably come up with some other tricks and tips to get the time down even faster. I’d love to know what you come up with.
If you can be efficient, you can program. That’s all this is, just looking at common problems you have and then figuring out better ways to do them.
Initially you might not have a better way to do some task. You might just have to figure them out as you go. But over time, you start figuring out what to do and then you’re able to make edits to your own workflow and optimize. You might even be resourceful and ask others for better ways, or read books, articles, watch videos — all while gaining insight on how to do things better. And by doing so, you’re being a programmer — that’s what programmers do daily. It’s through this process, we become efficient programmers.
Okay, I get the process, so what should I start studying?
HTML & CSS can be learned in about a week’s time, especially if you just follow tutorials on sites like W3Schools.
In fact, “syntax errors” are the main reason why most people quit programming after the first few weeks of diving in. You could be missing a semi-colon somewhere in your code
; and just not see it for several hours. And unfortunately, even if you become a more “mid level” or “senior level” developer, syntax errors can still suck most of your time away — it’s the worst, almost at every level of being a programmer, there’s always some new syntax to learn when a shiny new programming language or code library comes out. (But you just have to tough it out, because you get better at adapting with time.)
Hence, you have to get over this hump initially. Unfortunately, no one can really teach you better than yourself how to write code that the program understands, mentors and teachers can guide you — but ultimately you have to do the practice. It’s like learning to type. You can’t just start typing 75 words per minute, you have to stumble around with the keyboard for a while until you feel comfortable looking away while you type.
The RoadMap From Here
If you feel good about making HTML pages (and you should after some practice), build some simple projects for yourself. Here are a few ideas to get you started:
- Make your own resume with HTML instead of a traditional Word Doc or PDF.
- Add in some CSS for styles, make your resume look pretty
- Add some images too
- Find a service that lets you create a simple website like Squarespace or WordPress, then paste in your HTML, CSS and images in the editors provided.
- Even better, get your own domain, hosting plan, then follow directions from sites like GoDaddy or HostGator on how to upload your HTML, CSS and images as a folder uploaded via FTP; then tie your domain name
(https://yoururl.com)to that folder. (This process is longer and more manual, but the upside is that it costs you almost nothing).
If you’re able to view your own website url, congratulate yourself — you just became a web developer!
Do you optimize, bro?
However, now comes the REAL work. Optimize. That’s what coding is all about. How can you take your work and make it less work for yourself? Can you automate some parts of your work, like how I use a dishwasher to help me do my dishes? You also need to think, and avoid logical errors — errors that are not in the code, but with the way you are thinking about solving a problem. Maybe the approach is logical to you, but not to someone else, let alone a computer.
Maybe you think the approach should work, but you end up wasting even more time actually implementing it (this happens to me when I forget my own fundamentals — think out the problem first in plain language, then hit the code). It may seem like extra work to write code out in plain English and then code, but trust me it’s a huge timesaver. There have been so many times I just wrote code out first (brute force approach), and it ended up not working and I ended up wasting close to a full work day. However, whenever I took the time to write the steps out in plain English, it ended up being so much easier to revise the English in a few minutes, and then write out perfect code thereafter! Hence, sometimes the problem isn’t the code, it’s just in the way you are thinking about how to solve the question. This is why I wrote this blog mainly with basic ordinary day examples instead of throwing you into code. Ordinary thinking often leads to extraordinary output.
Writing HTML and CSS is very manual, but if you join a community you might learn that you can use coding libraries that you can copy and paste into your own code, that will help you write code even faster than usual.
If you look through our community, you’ll see hundreds of posts about React, a library that allows you to create and update HTML elements through a very easy to use framework; one that can reduce your manual coding time from hours down to minutes of work.
While these libraries are really cool, at the end of the day, you can’t borrow the work of others and call yourself a true programmer. A good programmer optimizes, and thus you’ll have to come back to how YOU can write code better. But look to these libraries as sources of inspiration for how you too can eventually write libraries that save other people time. Use the cool libraries for now, then go back later and actually learn how they were written to help people, and you’ll help yourself get better.
You can improve your code literacy and ability to optimize by reading code from others. In doing so, you can gain more insight for yourself, and will learn new ways to do things you may not have come to on your own through practice. You can also look outside programming for ideas too — just doing simple exercises like optimizing your own dishes can make you think better when you’re face to face with a code block you’re working on.
Bottom Line, and TL:DR — Yes, You Can Learn To Code, Anyone Can
But it’s work. And you’ll have to be really committed to the process. That all said, it doesn’t have to take all your time — it can be done just like anything else through planning a few hours or so out of your own week to doing the work.
You can definitely learn to code while being a non-coder; so if you are a sales person who wants to learn to code, set aside some hours to do so. If you are a hair stylist, or a driver, you can learn to code if you set aside the time. It may feel alien to you at first, but I’ve met many people who “transitioned” perfectly from another career to programming.
Sure, you’ll be another programmer in a sea of programmers out there, but that’s actually a good thing — if you view this as an important skillset for yourself; the ability to optimize, you’ll stand to gain a lot more than your average non-coder can. Think of learning to code as the difference between being literate and illiterate in 2020 (and moving forward). If you never read, you limit yourself to what you only know. However by reading you open yourself up to a world of new ideas and adventures. I feel that way about learning to code too. Sure, I’m another programmer — but I’m thankful for it, because learning this skill gives new opportunities and saves me time, time after time.
Hope you learn to code!