25 Tips for New Developers: Advice from a (Mostly) Self-Taught Software Engineer
The most common question I get from blog readers is "What is your advice for new programmers?" So, I thought it was time to write up my thoughts.
I will write up my full story in the future, but I took two computer science classes in college. Then, I got a software engineering internship shortly after. I started doing web development work, initially on the backend and then eventually on the frontend. My college definitely did not teach web development, let alone within the first few computer science classes, so I taught myself.
I don't think my story is unique -- all programmers are self-taught to some degree, whether that's fully self-taught or that they have a masters in computer science, but they taught themselves RegEx along the way. In fact, self-teaching may be one of the most important skills you can have as a developer.
In addition to my own experience, I also teach people to code as my primary job and for organizations I volunteer with -- so this article is drawing on that experience as well.
The rest of this article will have my tips for started.
My Tips for New Programmers
1. Have your reason, and remember it
If you want to start programming, there has to be a reason for that. Whether its that you love writing code, you want to have a more lucrative career, or that you are doing a bunch of Excel work and you want to make that more efficient. Keep track of that reason; programming is hard, and you will get frustrated sometimes. It will be essential to keep that reason in mind to stick with it. You could put a sticky note on your computer, a note on your home screen, or (like me) write it on your mirror with a dry erase marker.
2. Build a solid foundation
This may be a unique piece of advice, but I think its really helpful. Before you start writing code, if you haven't looked at math in a while, I would revisit the concepts from Algebra 1. Most of programming is built on algebra 1 math -- i.e., functions and variables. Understanding these concepts outside of programming will be super valuable in the future. I recommend Khan Academy's Algebra 1 course!
3. Find a community
Another thing that will be really helpful is finding a community to support you as you start writing code. This community will be valuable because other people will be in the same place as you, offer resources that helped them, and offer encouragement. I would suggest finding a meetup in your area as the top solution here, even small cities tend to have a group somewhat nearby. If there isn't one, I would suggest dev.to and the CodeNewbie community as two excellent alternatives. CodeNewbie has a weekly Twitter chat, a Slack group, and podcasts to listen to. Dev.to has a bunch of blog posts and a #discuss tag where you can post your questions!
Want more advice on learning to code?Download my free Ebook!
4. Break down problems into smaller ones
One of the most important parts of programming is taking a large problem and breaking it into smaller and smaller pieces until those pieces are solvable. If you are looking at a blank text editor not knowing where to start, it may be because you haven't broken down the problem enough!
Related to the previous point, a lot of times it is beneficial to write down in detail what you are trying to do in plain words before even trying to write code. This process is called pseudocoding, and it can take whatever form you want it to. It can also be helpful to solve a problem really slowly on paper first, thinking about or even writing down the individual steps you are taking to solve that problem.
6. Embrace the cycle of learning
If you're learning to code as a second career, especially if you've been away from the classroom for a while, learning how to learn is going to be a big part of your process. There are lots of ups and downs involved, which is very natural! I would brace yourself for that rollercoaster before starting out.
7. Start with free resources
There are a million and one resources for learning how to code. Some are free, and some are paid. I would start with the free resources, make sure you like writing code, and then after that, you could think about moving onto paid resources or even a bootcamp. I have a post about my favorite free learn to code resources here.
8. Find your niche
There are a lot of worlds within programming, find one world that you love and focus on that. Instead of trying to learn 8 programming languages, frontend and backend, compiled and interpreted languages, all the text editors and developer tools, etc. Find a few things you are really interested in and get good at them.
9. Get good at pattern recognition
Recognizing patterns in code is one of the most important skills you can have. When people talk about writing "DRY" code (i.e., Don't Repeat Yourself) they are talking about reducing the patterns in your code. I recommend the game Set for pattern recognition -- you can even play online each day on the New York Times' website!
10. Make good habits early
It will be easier to write clean code in the future if you get into the habit early. Bad habits can be hard to break. Here are my tips for writing cleaner code. If you are doing web development, running HTML and CSS validators on your code can tell you exactly what to fix!
11. Identify your learning style
Everybody learns differently -- whether that means you are a visual learner, love videos, need somebody to push you, or you love documentation, you will learn best differently than the person next to you. Identify how you learn best, and rely on resources that fit that style well. For example, I learn best from reading documentation and code examples from that documentation, and I lose focus easily in tutorials.
12. Struggle, but not too much
Struggling a little bit when you are learning is really important so that you can solve the problem yourself and find an answer using resources that exist. That being said, it can become unproductive and demotivating to struggle with a problem for too long. After a few hours, reach out to someone for help!
13. Get comfortable with failure
Programming is hard, and finding the right answer won't be immediate. One of the most pivotal moments in my programming journey was failing at writing a Sudoku solver. It can be challenging to adjust to not getting everything right away and seeing those error messages, but that is a huge part of programming.
14. Love your error messages
Error messages are super helpful, but when you are starting out that red error message can be terrifying! One huge step to take is to read through those messages, understand them, and then use them to solve the problem. In fact, you will get to a point where a program silently failing will be far more annoying than a useful error message!
15. Some programming languages are easier than others
16. You don't need to know everything
It is straight up 100% impossible to know everything about programming. Nobody knows every programming language, every single method that's out there, every library and framework, or the perfect solution to every problem. Don't worry about learning everything, just focus on what you do know and extending that.
17. Depth over Breadth
Learning one thing in depth is better than learning a tiny bit about a lot of things, especially at first. That in-depth knowledge will carry over and make learning that next thing easier. Put the blinders on, so you don't get tempted to drop what you're learning and move to something new.
18. Focus on the fundamentals first
The fundamentals of programming are invaluable, and you will use them no matter what you end up doing with programming. Focus on having a solid knowledge of loops, conditionals, functions, data types, and (in most languages) object-oriented programming before moving on to learning about that awesome library that everyone's talking about. It will be so much easier to learn that library once you know the fundamentals really well. They will also carry over from language to language, so you only have to really learn them once -- after that it's just syntax!
19. Get good at Problem-solving
20. Get good at researching
21. Build projects you love
When you're learning, you will be building various projects to practice (and show off) your skills. Pick project ideas that are interesting to you; you will be much more likely to finish them and want to put work into them. Related, complete those projects. A few really good finished projects is way more impressive than a bunch of half-finished ones!
22. Compare yourself to only yourself
There are a lot of people learning to code out there. Don't compare your progress to someone else's, instead compare yourself to previous you and focus on your own growth.
23. Do a bunch of code challenges
Doing quick code challenges can really help solidify the fundamentals. They are great for problem-solving and practicing for interviews. I post one on Twitter every day with the hashtag #CodingPuzzle if you want someone else to solve them with!
24. Celebrate your wins
Learning to program can be a really difficult process, so when you accomplish something, even if its small, celebrate it! I keep track of my wins in Google Keep so, if I have a bad day, I can come back to those wins and remember them!
25. Programming is awesome
Programming is really cool because you get to build things. I always come back to this Sandi Metz quote:
Those of us whose work is to write software are incredibly lucky. Building software is a guiltless pleasure because we get to use our creative energy to get things done. We have arranged our lives to have it both ways; we can enjoy the pure act of writing code in sure knowledge that the code we write has use. We produce things that matter. We are modern craftspeople, building structures that make up present-day reality, and no less than bricklayers or bridge builders, we take justifiable pride in our accomplishments.
This all programmers share, from the most enthusiastic newbie to the apparently jaded elder, whether working at the lightest weight Internet startup or the most staid, long-entrenched enterprise. We want to do our best work. We want our work to have meaning. We want to have fun along the way.