//...
// <insert arithmetic sequence formula here>
// FUCKED UP ARITHMETIC SEQUENCE REMOVED
// Reason: program was not obeying the rules of math!
// ...
Has this ever happened to you? (AKA proof that I am insane)
At one point during 4E5, I had to write some code that would make certain that the map would not scroll so far as to allow the player to see the edge of the map. For some reason, it simply would not work. I ended up writing a piece of code that would solve an arithmetic sequence and that solved the problem.
The next day, I went back to work and it stopped working. I went back, looked at it, and wondered why it stopped working. I went back to the piece of code and fooled around with it, and eventually got it working again. The thing that struck me as odd was that a) the sequence had worked in the first place and b) that the final code was EXACTLY the same code that originally wasn't working.
I ended up commenting out the code and inserting this right before it:
Has this happened to anyone else, or have I gone completely insane?
I've had this sort of thing happen multiple times. Finally working code one day, screwed up the next. No idea why or how. There are strange gnomes living in my PC.
I have seen that type of thing before, and would swear the laws of logic were breaking down. But I always solved the problem, and it is usually a wierd memory thing. The other thing that has messed me up for a while was doing if(a=1)... instead of if(a==1). Sometimes the double = is just not obvious enough.
This has happened to me before. I run the program once, and it works fine. I come back after, say, dinner, and it no longer works...
I have yet to figure it out.
I have yet to figure it out.
This type of problem is usually a case of an inverted sign on a value. For example, you intended to write A+B but actually wrote A-B. In a large equation, some of those problems can be difficult to catch.
I had it too once, it's maddening. What's even worse if you then hack a solution out of frustration and delete the buggy code, knowing well you solved it by 'accident' but fail to reproduce, left forever wondering what it was that you didn't understand BY YOUR OWN FAULT...or maybe it's just me.
Your not insane...the Gnomes Are Among Us. They stalk programmers and quietly modify your code in tricky ways when your not looking. They change comparitive signs from == to = or !=. They pervert your arithmetic by changing +'s to -'s or modifying your ()'s. They hunt down your semi colons at the end of lines and delete them with prejudice, preferably in a production enviroment where you have to hunt down the logs to find out what line in the 91284908120941209 lines of code the semi colon has vanished in. They create the dreaded memory leaks of DOOM!
You must pay tribute daily to the Gnomes^Nth or they will consume your programs with monkey wrenches and perversions of intent.
(Or you just f***** up and didn't notice it in a big formula)
Whichever floats your boat. =)
Personally, I'm convinced I'm perfect and the gnomes are the ones that screw my programs up. =)
You must pay tribute daily to the Gnomes^Nth or they will consume your programs with monkey wrenches and perversions of intent.
(Or you just f***** up and didn't notice it in a big formula)
Whichever floats your boat. =)
Personally, I'm convinced I'm perfect and the gnomes are the ones that screw my programs up. =)
I find that offering the gnomes in my computer my beloved Mountain Dew tends to appease them. How about yours?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement