11
My 'Hello World' program kept crashing until I realized I was using a single equals sign in an 'if' statement for 3 days straight.
I was staring at my screen in my dorm room for an hour last night, totally stuck, until a friend casually asked if I meant to assign a value instead of compare one (you know, like 'if (x = 5)' instead of 'if (x == 5)').
2 comments
Log in to join the discussion
Log In2 Comments
maxmurphy1mo ago
Honestly though, is that even a big deal anymore? Most modern compilers throw a warning for that. My IDE puts a squiggly yellow line under it before I even finish typing. It's a classic mistake, but getting stuck for days on it seems wild. Maybe you need to check your compiler settings or something.
3
elliotr391mo ago
Seriously, you can't just rely on the tools to save you! The whole POINT of learning is to get it right yourself. If you lean on warnings too much, you never really learn why the double equals matters. What happens when you switch to a language that doesn't catch it, or you're reading old code? That basic mistake shows you don't understand the core idea, and no squiggly line fixes that.
1