Keep Programming Fun

Following comments chosen from here are claimed to have come from real code.


long long ago; /* in a galaxy far far away */ 

// drunk, fix later

#define TRUE FALSE // Happy debugging

return 1; // returns 1

const int TEN = 10; // As if the value of 10 will fluctuate...

/* This is O(scary), but seems quick enough in practice. */
Followed by a loop with 4 nested loops

// Replaces with spaces the braces in cases where braces in places cause stasis 
$str = str_replace(array("\{","\}")," ",$str);

try {
...
finally { // should never happen 
...
}

private Logger logger = Logger.getLogger(); // Logger

// uncomment the following line if the program manager changes her mind again this week

// This should fix something that should never happen

// This is a walkaround for bug #7812

Written by one of our Chinese programmers, for whom English was not his first language.

This seems to stop morons from messing my code:
// Autogenerated, do not edit. All changes will be undone.

# Christmas tree initializer
toConnect = []  
toRead =   [  ]  
toWrite = [    ]   
primes = [      ]  
responses = {}  
remaining = {}

// I am not responsible of this code.
// They made me write it, against my will.

// TODO: Fix this. Fix what?