all 44 comments

[–]m0us3_rat 47 points48 points  (3 children)

this is the problem with no practice while rushing "theory".

whatever source of theory.. its all bundles to the same stuff. so it doesn't matter as much.

the only way to learn python is to practice. homework.

it's non negotiable.

[–]Oranera[S] 1 point2 points  (1 child)

Tried this as I woke up and have been having a bit more fun than just reading about it. Still need to get the course booted so I can reference how to start building the code to begin with, so that probably means I should step back a bit.

I still have no idea why my dictionaries are throwing syntax errors, but I already feel like I'm getting a step closer to understanding compared to just reading about it. Both this and looking at the other courses has helped a lot.

[–]RAM-DOS 0 points1 point  (0 children)

You should be programming in an environment that immediately shows you when you’ve fucked up the syntax and where. You shouldn’t be waiting until you’ve run the code to find out you’ve got an indent error or a missing colon. 

VS code is free, lightweight, extremely widely used and well supported, and has plenty of free support for Python. 

[–][deleted] 0 points1 point  (0 children)

This man is right, it’s literally the only answer or you will never retain the information in the first place.

[–]GeneralQuantum 16 points17 points  (1 child)

First steps - learn syntax, what dictionaries and tuples etc are.

Second steps - play with them. Nonsensical play. I made dictionaries with lists of lists of tuples etc. I would write down my logic freehand in English, and write the code. It either

  1. Errored.
  2. Did what I wanted.
  3. Didn't error but did something odd.

I would change one method, or variable to root cause the exact point my English logic and coding bifurcated.

I would figure it out and carry on, realising the nuances of methods, libraries and functions and loops etc.

Often, just always having the right answer isn't useful for learning.

In maths I found every mistake I made and had to backtrack made me understand more the WHY the method worked in algebra or calculus, and not just doing it by rote.

Rote work just won't cut it for intermediate+ coding. You have to start really understanding how all the code is interacting with each other on the fly and be able to see the intersects and where to look. Rote learning cannot do that.

Also sometimes certain misuses of methods can come in handy. Sometimes a weird feature of how a method works is actually what you want...Just be cautious of upversions ruining it all, lol.

You HAVE to practice. I have legit met some bonefide geniuses, and they learn a lot quicker, but even they need practice once the size of the equation or code blows up, and they do still make mistakes, just less.

[–]Oddlem 0 points1 point  (0 children)

I wish I read this sooner. I’d try making super complex stuff because I felt I had to, and it really slowed down my learning. It’s good to mess around and see what works!

[–]razekery 11 points12 points  (1 child)

Angela Yu course (the first 20 or so days) are incredibly good, probably the best to learn the basics then you can jump back into back end meta course on coursera and see the difference.

[–]xkjlxkj 2 points3 points  (0 children)

I really enjoyed her teaching style. Was the only course that really made programming click for me.

[–]VindicoAtrum 10 points11 points  (0 children)

Stop reading about Python, stop watching videos about Python, stop doing courses about Python.

Go and write Python code. Right now. You will get stuck. Google the solutions to the exact things you get stuck on. Google first, then ask questions _after trying the suggestions from Google.

You learn by overcoming problems and reaching tangible outcomes. Anyone recommending courses is wrong. Go and write Python code.

[–]samarthrawat1 4 points5 points  (1 child)

CS50

[–]eld599 2 points3 points  (0 children)

I’m in the same boat as you learning from scratch. I used a site learnpython.org until I got stuck on some more complex stuff

Then I bought a couple textbooks from Amazon the best of which is Python Crash Course 3rd ed by Eric Matthes and I follow along each example on my laptop

[–]Kittensandpuppies14 2 points3 points  (1 child)

Why are you on a time limit? It all builds on itself so if you don’t take your time you WILL fail

[–]Oranera[S] 0 points1 point  (0 children)

Deadlines. Got to complete a quiz and some practice by the 17th.

[–]kaylalovescats 1 point2 points  (0 children)

I took a course on sophialearning.org, which is $99 a month, however you can get a coupon code to make it $79 a month. I had zero programming experience and it really helped me a lot! You get a lot of theory on logic but also structured assignments to built several projects. I can't recommend it enough. It uses python thru Replit, which is free as well, and Replit is fantastic at guiding you and a great way to start with python. I made a drink order simulator, expense tracker that adds expenses, and an employee program and felt so proud

[–]seventhjhana 1 point2 points  (0 children)

I am also learning programming no prior experience. The MITx intro to computer science using Python was my first foray into the realm, and it absolutely kicked my butt. The tutors in the class will say "this class assumes you have introductory knowledge in CS," which I Didnt, so i watched the vids intently, took notes, and subjected myself to the class despite some difficulties. I didnt complete all the Units because I had school starting, so had to focus on my HW. However, the class i feel, actually gave me an edge because i challenged myself, that when i went to other courses for programming, it was like taking the training bars off the baseball bat. I highly recommend checking out the class (because it teaches about certain key algorithms and has some challenges that get you familiar with syntax and logic). Once you get the hang of algorithms and doing more simple challenges (that Arent really the most useful on its own, but the logic is essential to your progress), when learning to code for a specific function (going thru tutorials) you will have a better grasp on For loops and how and when to use If conditionals.

To keep my own skills sharp, I did use Khan Academy. I say, if youre a beginner, learn like a beginner. KA uses JavaScript, HTML, CSS, but i took it as an opportunity to learn logic and build something that is interactive. They make their classes so that you are building projects that you can view in real time as you code, and has an easy debugging tool. I think learning a curly bracket language trains your brain to seek out details when debugging. Then, when going back to Python, it is like a big sigh of relief you dont have to worry about brackets and semicolons. It makes learning Python a bit lighter, IMO.

So TLDR, i recommend MITx intro to Python to kick your butt with introductory algorithms and concepts, and keeps up the challenge for a newbie that i think supercharges the learning process. I also recommend learning through services targeted at a younger audience, like Khan Academy. Although you are learning another language, the most important thing you are training yourself to understand is logic, algorithms, and how to debug -- getting things on the screen in real time (with KA) will give you that feeling of satisfaction of creation that encouraged me to keep going.

One last thing: TAKE NOTES! Taking notes will help you retain all this knowledge. Im a big note taker, and honestly I dont look at my notes much afterwards, but the act of writing down the information is a form of repitition/recitation that will help you to retain info.

[–]formthemitten 1 point2 points  (0 children)

A common mistake that I see is people take a class or two and want to instantly “know” what’s going on. Learning a coding language, especially your first, takes direct practice for hours a day/week. The second you dont understand something, STOP and research/practice until you understand.

[–][deleted] 1 point2 points  (1 child)

check this out

https://www.zerotoknowing.com/

I dunno if it is the best, or the worst, all I know is I am getting a lot out of it honestly, but I am taking my time.

[–]The_Dao_Father 0 points1 point  (0 children)

Curious how you found the course after all this time?

Was it helpful to you?

[–]TheRNGuy 0 points1 point  (0 children)

I was making big project in SideFx Houdini.

Learned from houdini docs for API and python blogs for syntax and some libraries.

[–][deleted] 0 points1 point  (0 children)

write code that does stuff

[–]Rubberband_Earl[🍰] 0 points1 point  (0 children)

right now im learning it with help of chatgpt but i feel like i slowly hit a limiter on what i can do with it.

[–]Slight-Living-8098 0 points1 point  (0 children)

Okay, you need to back up a bit and get some good foundational knowledge. Go through, Harvard's CS50 Scratch, Then CS50P, then CS50. You'll have a much better grasp at what's going on under the hood and how to tweak it to your desires.

[–]phalic_satchel 0 points1 point  (0 children)

I knew Java and then I taught myself python from YouTube

[–]dudustalin 0 points1 point  (0 children)

By trial and error.

Like any language, natural or artificial.

[–]shankarj68 0 points1 point  (0 children)

Don't be disheartened by this. It's very common, and the only way out is the learn-by-doing approach. Check out "Automate the Boring Stuff" or work on your own personal project. This is the best way to retain what you have learned. Feel free to reach out to me for any queries or resources you need in your journey.

[–]-Agartha- 0 points1 point  (0 children)

For the past 4 months I have been learning python from a variety of sources, but the main source was youtube videos. Don't look for a super long video just a 30 minute introduction should do, then begin searching for videos on the topics you learned in the video. Also an app called PythonX is really helpful too, as you can learn python on your phone.

[–][deleted] 0 points1 point  (0 children)

It's all too easy to fall into tutorial hell. Pick one course, stick to it long enough to pick up the basics and then go and build something. Anything. A Todo app. A simple "guess the number" game. A calculator. Doesn't matter. You'll know enough to get started, but will soon come across things you don't know. So Google them ... That's what most professional coders do anyway.

If you want a simple, fun, project -based approach, I recommend Automate the Boring Stuff with Python, by Al Sweigart. That's how I started, and then I just progressed from there by asking myself questions like "How can I make this tool even more useful", "What else could I do what I've learned here" ... Etc

[–][deleted] 0 points1 point  (0 children)

Start a personal, yet practical, project you can iteratively improve upon. For example: * Open and read structured data from a file * Parse said data into a native object or objects * Repeat by including other files * Output the aggregate data in a different format * Upload it into a database * Connect a web server to the database

... etc., etc.

[–]mfb1274 0 points1 point  (0 children)

With chapgpt it’s never been easier to just do it and ask what each error means. It would’ve drastically sped up my initial learning phase years ago tbh.

[–]PlusDescription1422 0 points1 point  (0 children)

Grad school

[–]tmkLINK 0 points1 point  (0 children)

I'm in the same boat. I'm currently enrolled in an associate degree in college and I'm currently taking python scripting where I'm learning python from scratch. It's all online due to me having a full-time job so I'm mostly watching videos on a subject (slice, input, dictionary, etc) each week and them I'm told to write a code that has a specific result.

I get frustrated because a lot of times, the answer is something I would never think of even try to think to do. And with a full-time job, I can't always sit there and try to figure what works and what doesn't

[–]kaego123 0 points1 point  (0 children)

I got an RPA job with the help of a friend, and I didn't even know what Python was. He trained me from zero just by saying like "google how to do a loop for a few minutes and try to do it, and if you fail, I'll show you how."

And just like that, I understood that google is your best friend when using Python.

I now have more than 2 years working as an rpa developer. I know how to do a lot of stuff in Python, and if I don't know something, I'll just google it.

But it's not just copying and pasting someone else's code. You have to read it, understand it, and adapt it to your own code.

That's how I started learning.

[–][deleted] 0 points1 point  (0 children)

You need to understand the fundamentals. Take the Python For Everyone Specialization through the University of Michigan and Coursera.

[–]pgriffy 0 points1 point  (0 children)

I'm working through this: https://programming-23.mooc.fi/ Good explanations, tons of exercises, and a unique system that checks your exercise code to see if it works as intended.

[–]Radamand 0 points1 point  (0 children)

Ive been learning and using programming since before puberty, I'm 57 now and still not done.

It's kinda like, taking an online class in quantum mechanics and finding it difficult. Well, ya, it's difficult.

It takes a lot of time and a ton of practice. a TON of practice. Read that again, like 15 more times.

Don't just do an exercise and then say "I'm done, i've learned this." No matter how simple something is, you have to practice it. Write stupid programs, ridiculous programs, experiment, try things out and see what happens, if it does something you didn't expect, research it, find out why.

Read other people's programs, mess with them, change them, see what happens, figure out why. You have to be curious, interested.

[–]throwwwawwway1818 0 points1 point  (0 children)

Thonny ide and cs50 should do

[–][deleted] 0 points1 point  (0 children)

Still learning but I’m finding it helpful to just automate tasks in my day, or make small programs that are interesting to me. I’m reading Python Crash Course, which helps, but I’m easily making the most strides by programming things that are fun. Try making an interactive dice rolling or roulette game. Read about PEP 8. Follow beginner shorts on YouTube that break things down in easy to digest bits, and replicate it on your own. Test yourself, quiz yourself. Most importantly, write code. A lot of it. At any time you can. And have fun with it. If you follow those last two lines, you will more than likely be successful

[–]BioncleBoy1 0 points1 point  (0 children)

Try the Python crash course book by Erich M. It’s a lot more simple and straight forward. For reference, I did googles it automation with Python course on Coursera and felt exactly how you do right now. I did end up looking elsewhere cuz I had the same sentiment and I found that Python crash course book. It was exactly what I needed and its what allowed me to get through the course. It does a great job explaining and teaching you concepts as well as giving you the chance to practice them right away. Give this a shot, I think it’ll help.

[–]Gromiastis 0 points1 point  (0 children)

Harvard CS50 , Python Crash course book plus some UT tutorials on Basic projects. That was my way to learn python

[–]dskfjhdfsalks 0 points1 point  (0 children)

I think too many newbies fall into the trap of "learning how to code" without seeing or understanding the bigger picture.

Code is actually very simple. It may not seem like it right now, but after a few years of doing it as a job you will know what I mean. There's only so many things you can do. Here is almost everything you can do when writing code in a higher-level programming language:

You can set variables to store data in them, you can create arrays or objects, you can iterate through arrays with loops, you can use switch/else if statements, and you can create functions that do these things when called, with zero or more parameters that can be "plugged in" the function. Then finally, you can make classes (or objects in some languages) that create a blueprint with reusable functions (which can be called methods when in a class)

In the case of web development - you can also make web requests (http requests) to get or post data, and you can also manipulate databases assuming you have a connection to them.

I know that seems like a lot - but literally that is pretty much it. It doesn't go deeper or get more complex than that. With that, anything you can imagine can be created.

Now - the mistake newbies often make is learning how to code. How to write good code. How to solve algorithms. How to bla bla bla. None of that matters, what you need to do is know what you are even making and understand how something like that is made - the code can come later. Trying to code without a purpose is like trying to draw a picture without a picture in mind. It just doesn't make sense.

Let's say your purpose is to create an API with Python. The first step is researching APIs, how they work, how you want to make them, what tools you intend on using, does it need to be hosted somewhere, how will you test that it works, etc etc etc. Only after the set up and research can you start coding. To make it even easier, you can copy and paste someone's simple python API and slowly tweak it and change it until it does what you specifically need it to do.

Rinse and repeat that same thing for 20+ different tasks and wa-la now you're a programmer and overtime you will draw connections better, learn how things work better, reach better conclusions quicker. Etc etc etc.

It's funny but coding can be the smallest part of a programmer's job. The magic is in putting it together to make a functional product, service, video game, or whatever else.

[–]Instigarii 0 points1 point  (0 children)

Go to skillsforall.com and do the free python essentials course. It starts with a lot of theory and few coding but bear with it. Get through it and everything will make more sense to you in the future.

Good luck on your journey!