I decided, on a whim, to look at some code I wrote for computer programming classes back in my freshman year of college. That seems so long ago now. I have changed so much. Still, the things I did back then are amusing to me. I wrote all kinds of weird notes to Gary (the professor grading my projects) in the comments. Here are some that made me laugh:
Before some arithmetic:
//this fixes that stupid buisness of chars being negative instead of > 127
//that makes me so mad
Before a really ugly function:
//display the board in ASCII format
// i'm sure this function appears gargantuan and incomprehensible - just trust me that it works
//dont' even look any further
Before a bit of code that appears a few times in various forms:
//i suppose i could have written an inline function
//but i really dislike inline functions
//they seem like a waste of time to me
At the end of a compression program:
// MAKE SURE YOU CLOSE THE FILE or else all manner of nastiness shall ensue
//because the last few bits won't get written
//so the decompressor won't hit an EOF
And, my favorite, before calling function I write for a Heap data structure. I gave it a name different from the ‘canonical name’:
/this function below is equivalent to MaxHeapify
//but i think that's a dumb name