How to finally learn to code in 7 easy steps


Whether you’re diving into your first programming language or adding another to your repertoire (let’s become polyglot!), there’s one thing many of us share: the journey of learning to code on our own. In today’s world, it seems easy to embark on this journey, given the plethora of resources at our fingertips. However, this abundance brings its own set of unique challenges.

Learning to code independently often leads to what is known as the famous “tutorial hell.” It’s a common trap where learners, in their quest for the perfect guide, find themselves circling in a maze of tutorials. This endless search makes every tutorial appear indecipherable. And even when the right tutorials are found, months can pass in study without the satisfying sense of real progress, leading to weariness and frustration.

Another significant hurdle is the ever-elusive ‘perfect time’ to learn. Many struggle to find or make time in their busy schedules to dedicate to coding, further prolonging their learning journey. If you need advice on that we have a nice blog post for you: “The two-minute rule for busy coder/learner”

But fear not! The following 7 steps are designed to help you navigate these challenges more smoothly and effectively, ensuring you won’t face the same obstacles that have hindered others. These steps are:

  1. Make a roadmap: Plan your learning journey.
  2. Choose the right resources: Select materials that suit your learning style.
  3. Take notes along the way: Documenting your progress aids in retention.
  4. Learn the basics thoroughly: Strong foundations are key.
  5. Engage in projects: Apply what you learn in real-world scenarios.
  6. Revisit the basics: Regularly reinforce fundamental concepts.
  7. Collaborate: Learn from and with others.

In the rest of this article, we will dive deep into each of these steps, providing you with practical advice and insider tips to make your coding journey a successful and enjoyable one. So, let’s get started and turn those coding dreams into reality!

0. Help! I don’t know what to learn!

Note: If you exactly know what you want to learn you can skip this part!

If you’re feeling overwhelmed about where to start your coding journey, you’re not alone. “What should I learn first?” is an increasingly common question, not just due to the vast array of options available, but also because of the ongoing ‘wars’ between different programming languages, each claiming to be the best. Navigating through these passionate and often subjective debates can be tricky. It can lead to two main issues: difficulty in making a choice (which breeds procrastination) or ending up with a language that doesn’t really suit your needs.

Take, for instance, the classic debates like “The best programming language for…”, “Which JavaScript Framework to choose?”, or the famous “Python vs. R”. These discussions are recurrent and can be more confusing than helpful. So, how do you cut through the noise?

The simplest approach is to avoid starting your search on the Internet. Instead, make a list of your own needs and objectives. On the Internet, there’s a risk that others will decide for you, pitching a language as the be-all and end-all (though, thankfully, not everyone does this). Approaching with a clear idea of what you want to achieve helps limit undue influence and indecision.

Also, consider the support and resources available around you (friends, colleagues or books) and align them with your personal or professional plans. If you’re still in doubt, it’s okay to pick an option at random or go with a ‘default’ choice. Don’t linger too long in this phase of decision-making. Remember, you can always pivot to another language later – no learning is ever wasted.

The beauty of programming is that the core concepts are often transferable between languages. Different programming languages are just tools – it’s how you use them that matters. For example, if you start with Python due to its simplicity and later decide to switch to Java, you’ll find that many concepts like loops, variables, and data structures are similar, just with different syntax.

But who to talk to?

It’s a legitimate question - as a beginner, we don’t necessarily know how to translate our needs into clear, domain-specific objectives. Before going on the Internet, it’s always wiser to talk it over with a more advanced acquaintance. Now, in the age of artificial intelligence, an in-depth discussion with a model like ChatGPT can be enlightening (but becareful it might be biased!).

In summary, step zero is about making an informed, yet not overthought, decision. Choose a language or a technology based on your current needs, availability of resources, and your future goals. And remember, the journey of coding is flexible – it’s perfectly fine to change paths as you grow and discover more about your interests and the tech world.

1. Make a roadmap

The journey of learning to code is akin to embarking on a voyage – having a roadmap is crucial. The path of least resistance often leads to joining online curricula or courses on platforms like [Coursera](, Udemy, or freeCodeCamp. While these courses are beneficial and circumvent the need to design your own program, they are, by nature, very standardized. They may not align perfectly with your objectives or your preferred learning style.

If you find that these courses don’t meet your unique needs, crafting your own roadmap is a viable alternative. It’s tempting to dive straight into tutorials and start coding, but this approach can often lead to confusion and discouragement. The key is to have a clear goal. You should be able to answer questions like, “Why do I want to learn this programming language?” or “What do I specifically want to create with it?” Remember, a programming language can serve many purposes – from developing websites (like HTML/CSS/JavaScript for front-end development) to creating data analysis tools (such as Python for data science).

Once you’ve defined your objective, the next step is to break it down into smaller, achievable, and measurable goals. For instance, if your aim is to build a website, start by learning basic HTML and CSS. Then, gradually progress to more complex tasks like JavaScript and back-end development.

With these smaller goals in mind, order them and compile them into a learning roadmap. The more personalized your roadmap, the better. However, it’s essential to start with the basics regardless of your ultimate goal. At this stage, your roadmap doesn’t have to be incredibly detailed, but you should at least know what skills you need to acquire at each stage.

Don’t underestimate the importance of this planning phase. Dedicate a good amount of time to it – up to two weeks, if necessary. During this period, don’t hesitate to seek advice from more advanced individuals or even artificial intelligence platforms. Compare your plan with roadmaps recommended by others to ensure you’re on the right track.

Remember, your roadmap is not set in stone. It should be a living document that evolves as you gain more knowledge and understanding of the subject. You can’t know everything from the outset, and it’s perfectly fine to adapt your plan as you progress. Especially when it comes to projects (see “6. Engage in projects”).

In conclusion, a well-thought-out roadmap tailored to your specific goals and learning style is an invaluable tool in your journey to learn coding. It provides direction, keeps you focused, and helps measure your progress, setting you up for a successful and fulfilling learning experience.

2. Choose the right resources

Selecting the right resources is a crucial step in making your roadmap more tangible. It’s not necessary to have resources for every step right away; you can discover new resources as you progress. The key is not to get bogged down in finding the ‘best’ resources, as this can be a laborious and often futile task. Focus on finding resources that best suit your learning style.

To help you with this, ask yourself some guiding questions: - “Am I willing to spend money to learn?” - “Do I prefer paper or digital resources?” - “Do I prefer static or interactive resources?”

For each of these combinations, there are corresponding resource types: - If you’re open to spending money and prefer paper resources, consider investing in comprehensive coding books. - If you prefer digital and are willing to invest, paid online courses on platforms like Udemy or Pluralsight offer structured learning paths. - For those who prefer free resources, there’s a wealth of YouTube tutorials and online documentation. - If interactive learning is your style, platforms like Codecademy or freeCodeCamp offer hands-on coding exercises.

For more interactive learning ressources (exercices) I wrote a blog post here: “Free programming exercice website”.

It’s important to note that preferences might change based on your experience level. For example, if you’re learning your second programming language, you might find more advanced resources like technical blogs or community forums more beneficial.

However, each type of resource has its shortcomings. Books can become outdated, online courses might not cover the latest technologies, and videos can sometimes lack depth. Don’t hesitate to ask for recommendations from experienced coders or online communities for a list of useful resources.

A great way to start strong is by taking a crash course (written or video) of maximum 2 hours, and coding along with it. This approach helps you quickly grasp the syntax and philosophy of the language. Remember, it’s crucial to practice actively and not just passively follow along with the theory. For more advanced programmer with a good understanding of programming concepts reaching their new programming language a website like “learning x in y minutes” might be a good ressource.

Keep in mind that there’s no such thing as a perfect resource. It’s okay to change your resources as you progress. The most important thing is to work hard and stick with it for as long as possible.

Now that the beginning of your roadmap is set, you’re ready to embark on your coding journey with confidence. Remember, the journey of a thousand lines of code begins with a single keystroke!

3. Take notes along the way

Take notes

This section emphasizes a good practice crucial for avoiding stagnation and deviation in your coding journey: taking notes throughout the learning process. While some programming languages like Julia have exceptional documentation, others like Python boast a plethora of tutorials by individuals. Then there are languages with more challenging documentation, such as Haskell or Nim. But ultimately, the best documentation is the one you create for yourself.

This can take the form of personalized notes in a style that suits you best, be it a text document, a Word file, or a Markdown file. Another vital type of documentation is the code you write yourself. Ensure it’s clean and well-commented (but not excessively so). This code becomes a valuable resource when you need an example later. Additionally, organize your code and folders effectively to easily navigate your work.

Finding help

When it comes to seeking help, autonomy should always be your first approach. This means trying to solve problems on your own by testing and researching, sometimes for hours, before seeking external assistance. Remember, making mistakes is a fundamental part of learning. Relying too heavily on others for answers – whether it’s a more experienced colleague or the internet – deprives you of the crucial problem-solving experience at the heart of programming.

The risk with relying on artificial intelligence for help is that it can provide answers without limit, which can lead to a dependency on external solutions. Without honing your problem-solving skills, your learning becomes slower and less effective, leaving you reliant on others or tools for coding. Strive for independence.

Learning best practices and tricks

It’s also important to learn the best practices and tricks of the language you’re studying. The beauty of these tips is that they can be learned at different stages of your journey. However, the sooner you incorporate them, the more quickly you’ll boost your productivity. Embracing these best practices early on is always beneficial.

In summary, keep detailed notes, stay organized, seek autonomy in problem-solving, and continuously learn best practices and tricks in your chosen programming language. These steps are fundamental in developing a strong foundation in coding, leading you towards becoming a proficient and independent coder.

4. Learn the basics thoroughly

The foundation of understanding any programming language lies in mastering its basics, which is why it’s a crucial first step in your roadmap. However, learning the basics isn’t just about grasping the syntax; it’s equally important to understand the philosophy behind the language. The best way to solidify your understanding of these basics is through practice exercises, underscoring the importance of choosing the right resources.

Universal concepts in programming languages

There are several universal concepts common to all programming languages that you need to ensure you master:

  1. Variable declaration: Understanding how to create and use variables.
  2. Data types: Familiarity with different types of data (e.g., integers, strings).
  3. Control structures: Knowledge of if-else statements, loops, etc.
  4. Functions/methods: Creating and utilizing reusable blocks of code.
  5. Input/output operations: Handling user input and system output.
  6. Error handling: Managing and responding to errors in code.
  7. Basic data structures: Using arrays, lists, and dictionaries.

As data scientists or statisticians, we have the impression that these concepts are not important to us as long as we don’t code as a programmer (we can use R without knowing how to program, for example), but this deprives us of essential knowledge that will help us in our learning process (in particular, understanding and resolving errors).

Tips for learning the basics

  • Take your time and don’t rush the learning process.
  • Practice as much as possible with small coding exercises.
  • Use your notes as a reference and keep updating them.
  • Don’t be too hard on yourself.
  • Don’t try to understand everything perfectly, you will come back to it latter if needed.

Estimated learning times for programming languages

Here’s an estimated learning time for various programming languages (non-exhaustive list), ordered from easiest to most difficult:

Programming language Level of difficulty Estimated learning time
Lua Easy 2-3 weeks
Python Easy 3-4 weeks
R Easy-Moderate 4-5 weeks
Julia Moderate 5-6 weeks
JavaScript Moderate 5-6 weeks
Go Moderate-Hard 6-8 weeks
Java Moderate-Hard 6-8 weeks
Rust Hard 8-10 weeks
Nim Hard 8-10 weeks
C/C++ Hard 8-10 weeks

Remember, it’s okay not to master everything at first. Your understanding will deepen as you work on projects and revisit the basics later. The most important thing is to take comprehensive notes during your learning process. You will come back to it latter!

In conclusion, give yourself time to thoroughly learn and understand the basics of your chosen programming language. This solid foundation will set you up for success as you progress in your coding journey.

Warning: You don’t want to go too fast, but you don’t want to take too long either. For the moment, it’s technical knowledge, but for it to become technical skills, we’re going to have to start working on projects, and as quickly as possible (see bellow).

5. Engage in projects

Projects are arguably the most effective way to learn programming. They encompass an array of steps, reflections, and errors, making them instrumental in understanding and applying the various tools and concepts you’ve learned. Projects make the abstract concepts tangible and help you start learning autonomously. If you haven’t already included projects in your roadmap, it’s time to do so. Projects will not only enhance your learning but also serve as benchmarks for self-evaluation.

How to choose your project

Initially, choose a very guided project, preferably one accompanied by a video or tutorial that leads you step-by-step. This will help you understand the project flow and the intricacies involved. After completing a guided project, move on to less structured projects. If you struggle to find suitable projects for your programming language, seek inspiration from the internet or ask someone experienced to help you select. Don’t hesitate to look at projects in other programming languages for ideas.

For subsequent projects, consider working on something personal and meaningful to you. This approach keeps motivation high and makes the learning process more enjoyable.

Project Ideas for different levels and specializations

Non-exhaustive list

  • Data scientist
    • Beginner: Analyze a dataset using basic statistical methods.
    • Intermediate: Create a predictive model using machine learning.
    • Advanced: Develop a complex data visualization tool.
  • Web developer
    • Beginner: Build a simple personal or portfolio website.
    • Intermediate: Develop a dynamic web application with a database.
    • Advanced: Create a full-stack application with user authentication.
  • Cyber security
    • Beginner: Set up a basic secure network.
    • Intermediate: Conduct a penetration test on a test environment.
    • Advanced: Develop a tool for automated security testing.

If you find yourself struggling with a project, it’s a sign you might need to revisit the basics or seek more documentation. It’s completely normal to oscillate between learning and applying. Creativity is a key asset in this phase, so let your imagination guide your project choices.

In conclusion, engaging in projects is an invaluable part of your coding journey. It solidifies your learning, enhances your problem-solving skills, and helps bridge the gap between theory and practical application. Remember, it’s about the journey, not just the destination.

6. Revisit the basics

Even as you progress and become more adept at your chosen programming language, it’s crucial to regularly revisit the basics. With the experience you’ve accumulated, your understanding of fundamental concepts will deepen, and you’ll often gain new insights. This revisiting is not only a refresher but also a means of reinforcing and solidifying your skills.

In my opinion, one of the most effective ways to strengthen your grasp of the basics is to teach or help others. Once you’ve completed your first project, you should be at a level where you can offer valuable advice to beginners. The power of teaching lies in transforming your practical, personal knowledge into accessible and comprehensible information for those who are just starting out. This process not only hones your pedagogical skills but also compels you to develop a clearer understanding of fundamental principles. You’ll frequently find yourself answering the daunting “Why?” question, which in turn deepens your own comprehension.

Additionally, teaching requires you to discern what is essential to convey, further clarifying your understanding of the basics. Engaging in online or in-person groups where you can teach or assist others is highly beneficial. It not only enhances your own skills but also contributes positively to the learning journey of many others.

If teaching directly isn’t your preference, consider creating written or video resources to share your knowledge. Documenting your learning process and explaining concepts in your own words can be just as enlightening.

And if you don’t think you have what it takes, don’t underestimate yourself! You certainly do!

In summary, revisiting and reinforcing the basics is a crucial step in your coding journey. Whether through teaching others, creating resources, or simply reviewing concepts on your own, this practice ensures a solid and continually evolving understanding of your programming language.

7. Collaborate

Collaboration is a cornerstone in the realm of modern programming. Far from the stereotypical image of lone geniuses coding in isolation, programming today is deeply rooted in social interaction, sharing, and collaboration. Without these elements, the landscape of programming – filled with free educational resources and open-source tools – wouldn’t exist as it does today.

The Importance of collaboration

Working solely on your own projects limits you to a single perspective. By collaborating, you expose yourself to different methodologies, ideas, and problem-solving approaches. This exposure can significantly enhance your skills and may introduce you to techniques and concepts that can dramatically improve your work. Collaborating on code and in learning environments brings numerous benefits, including:

  • Exposure to diverse coding styles: Understanding different coding styles enhances adaptability.
  • Improved problem-solving skills: Collaborating on challenges leads to more innovative solutions.
  • Networking opportunities: Building relationships within the programming community.
  • Feedback and peer review: Gaining valuable insights and suggestions for improvement.

Ways to Collaborate in Programming

There are various avenues for collaboration in programming:

  1. Joining coding communities: Platforms like Stack Overflow, Reddit, or local coding groups (like WeData) offer opportunities to interact with fellow programmers.
  2. Contributing to open source projects: Engaging with projects on GitHub or GitLab allows you to contribute to real-world software, understand codebases, and work with other developers.
  3. Pair programming: Working alongside another programmer on a project, either in person or remotely, facilitates a shared learning experience.
  4. Participating in hackathons: These events are great for teamwork, innovation, and testing your skills under pressure.
  5. Code reviews: Engaging in code reviews with peers can provide new insights and alternative approaches to problem-solving.

For each of these collaborative methods, consider concrete examples: - Communities: Ask and answer questions on Stack Overflow or join discussions on programming subreddits. - Open source: Contribute to a small open-source project on GitHub, fixing bugs or adding features. We have an article on that here: “Contributing to projects on GitHub” - Pair programming: Collaborate with a friend on a small project or find a partner through online coding forums. - Hackathons: Join local or online hackathons to work on innovative projects with a team. - Code reviews: Exchange code with peers for review, or participate in code review sessions within your community.

In conclusion, collaboration not only enhances your technical skills but also enriches your journey in programming. It opens doors to new ideas, methods, and connections, making your experience in programming much more rewarding and comprehensive.

Samira’s example

Let’s delve into the inspiring journey of Samira (imaginary character), a complete novice in Python, who embarked on a quest to master it for deep learning applications. Her story is a testament to the power of following the principles we’ve discussed.

The beginning

Samira’s journey began with uncertainty. She knew she wanted to dive into deep learning, but the path was unclear. After scouring through various reputable sites like Coursera, edX, and freeCodeCamp, classical social medias (Reddit, Twitter and YouTube) and Python’s tutorials, she decided to focus on creating web applications using Python to implement machine learning models. This decision formed the basis and goal of her roadmap, a path she was eager to explore.

Crafting the roadmap

With her goal set, Samira outlined her roadmap. She started with the basics of Python, dedicating weeks to understanding its syntax and philosophy. She utilized free resources like Python’s official documentation and YouTube tutorials for visual learning. Her notes were meticulous, filled with insights and reflections, making them a personal encyclopedia of knowledge. Her roadmap:

Phase 1: Grasping the basics of python (Duration: 3-4 weeks)

  • Week 1-2:
    • Focus on basic syntax, variable types, and basic operations in Python.
    • Resources: Python’s official documentation, beginner-friendly tutorials on YouTube.
    • Exercises: Simple programs like a calculator, basic data manipulation.
  • Week 3-4:
    • Introduction to more complex concepts such as control structures (if-else, loops), functions, and basic data structures (lists, dictionaries).
    • Building small projects like a simple text-based game or a to-do list application.

Phase 2: Intermediate Python and introduction to web development (Duration: 5-6 weeks)

  • Week 5-6:
    • Learning about APIs and how to fetch data from the internet.
    • Project: Building a weather application that fetches data from a weather API.
  • Week 7-8:
    • Introduction to web frameworks in Python (like Flask or Django).
    • Project: Creating a basic web application that allows users to interact with it.
  • Week 9-10:
    • Deepening knowledge of Python by exploring more advanced features.
    • Beginning to learn about databases and how to integrate them into her projects.

Phase 3: Diving into machine learning (Duration: 4-5 weeks)

  • Week 11-12:
    • Basic concepts of machine learning and data science.
    • Resources: Online courses on platforms like Coursera or edX, specialized in Python for data science.
  • Week 13-15:
    • Practical application: Starting with simple machine learning models.
    • Project: Building a simple prediction model.

Phase 4: Expanding skillset - learning R and Julia (Duration: 6-8 weeks)

  • Week 16-18:
    • Introduction to R: Focused on data analysis and visualization.
    • Project: Data analysis of a dataset using R.
  • Week 19-23:
    • Introduction to Julia: Focused on its application in machine learning.
    • Project: Implementing a machine learning model in Julia.

Phase 5: Deep learning and advanced projects (Duration: ongoing)

  • Continuously working on more complex machine learning and deep learning projects.
  • Collaborating with others in the field, contributing to open source projects, and possibly teaching beginners.

Of course her roadmap wasn’t like that at the beginning and she adapted it in the way. ### Engaging in projects

Samira’s first project was a simple Python-based calculator. Guided tutorials helped her at this stage, but she quickly moved on to more complex projects, like a weather prediction app. This project required her to delve into APIs and learn data handling in Python, a challenging yet rewarding endeavor.

Collaborative learning

Understanding the importance of collaboration, Samira joined a local coding club. Here, she not only shared her knowledge but also gained insights from more experienced programmers. This exposure broadened her understanding and introduced her to new perspectives and coding practices.

Expanding horizons

As Samira’s confidence grew, so did her curiosity. She ventured into learning R and Julia, recognizing their specific strengths in data analysis and machine learning. This expanded skill set allowed her to approach problems more flexibly, choosing the right tool for each task (sometimes mixing the languages for powerful projects).

Overcoming challenges

The journey wasn’t without its hurdles. Debugging her first machine learning model in Python was a particularly daunting task. The model’s performance was initially poor, leading her to revisit the basics and adjust her approach. It was a lesson in persistence and the value of continuous learning.

Samira’s growth

By applying the principles we’ve discussed, Samira transformed from a beginner to a proficient programmer, capable of handling complex deep learning tasks. Her story is a vivid illustration of how dedication, a well-structured approach, and the willingness to explore and collaborate can lead to remarkable growth in the world of programming.

In essence, Samira’s journey is a source of inspiration for anyone looking to start or enhance their journey in coding. It shows that with the right mindset and approach, the world of programming is not just accessible, but also a fertile ground for personal and professional growth.

Conclusion: the journey of learning to code

As we wrap up this guide, let’s reflect on the key elements that make the journey of learning to code both achievable and fulfilling.

  1. Make a roadmap: Start with a clear plan. A well-thought-out roadmap is your compass, guiding you through the learning process.
  2. Choose the right resources: Select resources that resonate with your learning style. Whether it’s books, online courses, or interactive platforms, the right tools are crucial.
  3. Take notes along the way: Document your learning. Personal notes are invaluable for reinforcing concepts and tracking progress.
  4. Learn the basics thoroughly: Solidify your foundation. Understanding the basics is essential for building advanced skills.
  5. Engage in projects: Apply what you learn. Projects bring theory to life and are critical for practical understanding.
  6. Revisit the basics: Revisit fundamental concepts. Teaching others and reviewing basics deepen your knowledge.
  7. Collaborate: Share and learn with others. Collaboration expands your perspective and enhances problem-solving skills.

Remember, learning to code is an ongoing process that values consistency over talent or speed. It’s about steady progress, not leaps and bounds. As the saying goes, “Slow and steady wins the race.” Embrace the journey with patience and perseverance.

As you embark on this path of learning and growth, remember that “Consistency is more important than perfection.”

Your journey in coding is not just about acquiring a skill; it’s about growing as a problem-solver, a thinker, and a lifelong learner. So keep curious, stay dedicated, and enjoy every step of this rewarding journey.