7

So I spent all day today trying to debug a C++ Program and after hours of digging into the code , I realized i had copy-pasted a for loop and had forgotten to change the loop variable from i to j. 😑

Comments
  • 1
    That's a bummer!
  • 1
    Welcome to devRant!
  • 1
    Try to declare your variables as close to the scope in which they're used as possible, that way something like this should be a compilation error. Live and learn!

    And welcome to devRant!
  • 1
    I try to avoid using i and j in loops, as this happened way too many times already 😂
Add Comment