I have this huge desire to learn programming but its stopped by me not being able to sit down and say “now its studying time” any advice is appreciated.

  • folkrav@lemmy.ca
    link
    fedilink
    English
    arrow-up
    4
    ·
    edit-2
    1 year ago

    I don’t have a good answer for the question in the title, but for programming specifically, I’d say try and solve a problem you have instead of studying it. It’s one of those things that’s IMHO much easier to learn by trying things out. Start small. Little things you’d like to automate, annoyances on your computer, things that could be useful for your work, etc.

    • 18107@aussie.zone
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      I find making a simple text based calculator is a good way to test your skills while learning.

      Start by adding 2 numbers together and outputting the result.
      Then upgrade the calculator by getting the numbers from user input.
      Now you get to decide the next upgrade. Does the user want to add 3 numbers? Perhaps they want to subtract instead. Maybe the user wants to start a new calculation immediately after finishing. What about error handling? What should the program do if the user enters something that isn’t a number?

      Each step provides new challenges and new learning opportunities.

      Make sure to test frequently. The more code you write between tests, the harder it becomes to track down bugs.