21
I finally understood loops after staring at a broken to-do list for 3 days straight.
That whole week I kept trying to manually print each task in my Python script until my friend in Seattle said, 'Just tell the computer to do it for you,' and the moment that for loop actually worked felt like magic, so what was the first coding concept that just clicked for you?
3 comments
Log in to join the discussion
Log In3 Comments
kevin_west2mo ago
That feeling when a loop finally works is pretty great. Though technically you were telling the computer to do it for you the whole time, just in a really slow way. The first thing that clicked for me was probably variable assignment, that an equals sign could mean something other than math. It made the whole thing feel less like a calculator.
9
Yeah that's a good point from @kevin_west about the equals sign. It really is the first big shift in thinking. For me it was functions, specifically how you can pass information into them. Seeing that you could wrap up a bit of code and then feed it different data each time made everything feel less rigid.
3
seanjackson2mo ago
Remember getting stuck on a problem for hours, trying to write every single step out by hand. Then I finally understood how to make a function do that repetitive work. It felt like cheating, like I'd found a secret door in the instructions. Suddenly the code wasn't just a list of commands, it was a set of tools I could build and reuse. That shift from writing every detail to building a helper changed everything for me.
3