4 ms·
Mel finally gave in and wrote the code, but he got the test backwards, and, when the sense switch was turned on, the program would cheat, winning
by thefreeman 12y ago
Mel finally gave in and wrote the code,
but he got the test backwards,
and, when the sense switch was turned on,
the program would cheat, winning every time.
Mel was delighted with this,
claiming his subconscious was uncontrollably ethical,
and adamantly refused to fix it.
I can't decide if its better if he intentionally did this, or it actually was an accident, but this was my favorite part by far.
- philh 12y agoThat seems like a difficult mistake to not notice while working on a "let me win" feature. For that matter, in general the code for "the computer should win every time" and the code for "the computer should lose every time" don't necessarily look anything like each other. They could do in this case, though. E.g. make the computer decide whether or not to bet based on the next card to be dealt, and accidentally reverse that test. (The test that he got backwards was clearly not "is the sense switch turned on?")