0
Day 14 of my Python course before I realized I was using else wrong
I was doing this Udemy course, 2 hours a night after work. Built a little calculator project. Everything worked, but I had like 30 if statements stacked up. One of them would always fire when it shouldn't.
Finally I watched a YouTube video from some guy named Corey. He showed how else attaches to the loop, not the if. My whole thing clicked. I spent the last 13 days typing else in the wrong spot.
Has anyone else hit that moment where one tiny syntax detail rewired how you think? What was your dumbest coding habit that took way too long to break?
1 comments
Log in to join the discussion
Log In1 Comment
mila_sullivan12d ago
Corey Shafer's the guy, and his video on loops actually made me realize I was doing the same thing, except mine was putting semicolons after every line and wondering why Python kept yelling at me. That moment when you find out the thing you thought was correct is actually the thing breaking everything, well, that's just the classic Python rite of passage.
9