DEV Community

Cover image for How To Stay Motivated While Learning to Code
Cole Caccamise
Cole Caccamise

Posted on

How To Stay Motivated While Learning to Code

Over the past 2 years, I have been attempting to teach myself to code. I have faced many hurdles, however, a lack of drive has been the largest roadblock in my journey. Actually learning the content isn’t the hard part, it’s having the motivation to continue. Now, this isn’t to say that it’s easy to learn code, because it’s not, it just takes serious dedication. Having the drive to learn is going to make the process much easier. For every trip-up you encounter, it’ll be easier to get back up when you truly want to succeed.

These tips are greatly aimed at beginners who are overwhelmed with the long road ahead but is not exclusive to them. Everything I’m about to mention is applicable to anyone, at any level. The truth is that you will NEVER stop learning, and will always need something to push you forward.

Before you read onward, I want you to ask yourself: Do I truly have a passion for code? Do I aspire to build things and solve problems? That is what coding, at its core, really is. If your answer to either of those questions was no, then coding may not be for you. Now, I’m not saying that having a passion for coding means you will never feel discouraged or tired. Coding is my biggest passion, yet to this day I still struggle staying on track at times. If you lack devotion and love for coding, you’re going to have an awful time. Learning is already hard enough, and without the motivation to do so, it’s going to be difficult to overcome the countless hurdles you’ll encounter.

Tip #1 — Have An End Goal In Mind

My biggest piece of advice is to have something that you want to work towards and accomplish in the long-term. This doesn’t be anything crazy, just something that you’re excited about. To give you an idea, I’ll share mine. I want to create content that inspires people and build a SaaS/Freelancing business that will allow me to work for myself in the next 5 years. Now, as I said, your dream doesn’t have to be as big as mine. You may just want to have the security of a typical 9–5 job, and that’s completely okay. Not everyone is fit for an entrepreneurial lifestyle and all of the things that come along with it. You might not even want to make a career out of code at all, and just learn it as a hobby. No matter what your end goal is, just make sure that it is yours.

Tip #2 — Stay Organized And Consistent

Try to turn coding into a habit. Set aside a time as frequently as possible that fits into your schedule. Whether this is 30 minutes or 3 hours, it doesn't matter. Obviously, the more serious you are about learning and the faster you want to get through it, the more time you’ll have to spend. Fun fact: it only takes around 21 straight days of doing something for it to become a habit. Once coding becomes as routine as brushing your teeth, it’ll be so much easier to sit down and get to work.

I recommend making a list of short-term goals for yourself for each week and put them into a calendar. This will divide up the content that you need to focus on and make it less overwhelming. I have really enjoyed using the app Notion to manage my time, but it did take quite a bit for me to tailor it to my liking.

Tip #3 — Have A Good Environment

I cannot stress enough the importance of having a good workspace. Having an area that you can sit down (or stand) in peace will increase your focus immensely, and in turn, help you to become more motivated. Make sure you are in a quiet space away from any possible distractions. If you can, try and leave your phone in a separate room to prevent you from being distracted. Turn on some non-wordy music like lofi beats that you can relax to. If your budget allows it, having a quality chair is one of the best investments you can make. After all, it is what you will be spending most of your time working in (unless, you’re using a standing desk, of course). I personally use the Autonomous ErgoChair 2, which I absolutely love. It’s pretty comfortable and for 369 USD, it’s not a bad deal.

Tip #4 — Prevent Burnout And Take A Break

It’s going to take an immense amount of effort to learn to code, but it's crucial that you still rest your mind. It’s not healthy to put all of your energy into this. Cut yourself some slack, and take a break every so often. During every coding session, make sure to take a break and go grab a glass of water, go for a quick walk, or just anything to clear your mind. It’s good practice to take a break every couple of hours or so. Make it long enough where you will feel refreshed upon returning but no too long that you have lost your motivation to continue. 10–15 minutes is a good rule of thumb.

Tip #5 — Be Disciplined

While I strongly believe that the previous tips will help you to stay motivated, there will still be times you feel discouraged. When you simply cannot find the drive to continue, it's up to your self-discipline to keep you going. The definition of discipline is the practice of training [yourself] to obey rules or a code of behavior, using punishment to correct disobedience. You need to make yourself code, even when you don’t feel like it. Circling back to my previous tip of having an end goal, recognizing that by continuing to learn, you are closer to your dream, you will have the strength to push yourself forward.

Closing Remarks

I have not had an extremely successful past with learning to code. It took me close to a year and a half to find the motivation to take this seriously. I realized just a few short months ago that I do truly have a passion for this field. Learning to code has been one of the most enjoyable experiences of my life and I am extremely grateful to have the drive to push myself harder every day. I hope that by following the tips I have outlined in this article, you can also find the motivation to continue on your journey. I wish you the best of luck and hope to see you again soon ;)

Thank you for reading! While you’re here, let me introduce myself:

My name is Cole Caccamise and I’m a Content Creator, Developer, and Tech Enthusiast.

Along with writing about programming here, I share similar content on YouTube, Instagram, and Twitter.

Top comments (3)

Collapse
 
jonrandy profile image
Jon Randy 🎖️

If you're having trouble staying motivated, you're probably doing it for the wrong reasons. You should be constantly, passionately curious about code and be moving forward because you want to - not because you feel you have to.

Follow the paths that interest you, not what everyone else says you should be learning or whatever is 'cool'. If you don't have a genuine enthusiasm and dare I say - aptitude - for programming, it'll end up just being another mindless task you're doing just to get a pay cheque

Collapse
 
cybeartron profile image
Cybear Tron

EPIC!!!!!

Some comments may only be visible to logged-in visitors. Sign in to view all comments.