C++
This is similar to some other methods, but I think slightly sneakier because at a glance it looks extremely straightforward.
#include "iostream.h" int main() { int TWO = 2; int F0UR = 4; std::cout<< TWO << " + " << TWO << " = " << FOUR; return 0; } #include "iostream.h" int main() { int TWO = 2; int F0UR = 4; std::cout<< TWO << " + " << TWO << " = " << FOUR; return 0; } This prints to the console:
2 + 2 = 5 The trick here is that "iostream.h" is actually a local file containing
Here the macro FOUR is defined to be 5. In the code body, the integer is F0UR, using a zero instead of the letter "O" as the second character. Depending on the font used, this difference can be very difficult to detect.#include < iostream > #define FOUR 5