Comments in code maken soms duidelijk wat de bedoeling is van mysterieuze functies. Maar soms ook niet. Het is ook ruimte voor melige ontwikkelaars om boodschappen achter te laten aan collega's. We struinden opnieuw StackOverflow, Reddit en Quora en meer sites en fora af op zoek naar grappige comments en dat leverde deze steeds verder uitdijende lijst op:

Comments waar je wat aan hebt:

int main(void)

/* Program starts here */

return 1; # returns 1

Geen comment, maar de opmerking hiervoor doet denken aan deze nuttige omschrijving:

# code below replaces code above - any problems?

# yeah, it doesn't fucking work.

Raadselachtige code:


// Dear maintainer:


// Once you are done trying to 'optimize' this routine,

// and have realized what a terrible mistake that was,

// please increment the following counter as a warning

// to the next guy:


// total_hours_wasted_here = 42


// This condition can't happen. Call the police or something.

//Magic. Do not touch.

//Peter wrote this, nobody knows what it does, don't change it!

<- DON'T TOUCH THIS SCRIPT -> XSLT is like arcane, black magic ->

//I am not sure why this works but it fixes the problem.


* You may think you know what the following code does.

* But you dont. Trust me.

* Fiddle with it, and youll spend many a sleepless

* night cursing the moment you thought youd be clever

* enough to "optimize" the code below.

* Now close this file and go play with something else.


//I am not sure if we need this, but too scared to delete.

/* You are not meant to understand this */

//When I wrote this, only God and I understood what I was doing

//Now, God only knows

Andere vermaningen:


/// Pay attention to this or I will hunt you down.

/// ...



* Do not use, ever - left in place for testing purposes


function I_David_WillHuntYouDownAndHurtYou_Badly_IfIFindThisUsedAnyWhereInTheAppLibrary(){



// The computer will explode if this is edited.



* Do not delete this comment; it is load-bearing. The template

* below is not greppable without it.




Boosaardige code:

#define TRUE FALSE

//Happy debugging suckers

# This is becoz you messed with me the other day

if == "#{my_x_employer}"

sleep(1000 * 3600)


// Hardcoded this for time sake ... will make andrew fix later :)

Woedende programmeurs



// Integrating it means DEATH.

// (see Revelation 6:8 for full details)

// TODO: Drive an ashen stake through the foul heart of this function.

public void BindCompany(int companyId) { }

// snip

private void MakeSureNobodyAccidentallyGetsBittenByRichardsStupidity()


// Make sure nobody is actually using that fucking bindcompany method

MethodInfo m = this.GetType().GetMethod("BindCompany", BindingFlags.DeclaredOnly |

BindingFlags.Instance | BindingFlags.Public | BindingFlags.NonPublic);

if (m != null)


throw new RichardIsAFuckingIdiotException("No!! Don't use the fucking BindCompany method!!!");


// P.S. this method is a joke ... the rest of the class is fucking serious


Wanhopige ontwikkelaars:

// I have to find a better job

// sometimes I believe compiler ignores all my comments

/* Please work */

// TODO: end this lunacy


// If this code is still being used when it stops working, then

// you have my permission to shoot me. Oh, you won't be able

// to - I'll be dead...

-- Change Log: Not needed. The code is perfect 'cause I wrote it.

-- If you change it, it will break.

//If you really feel dumb enough to ask a computer to figure out

//whether a number is even or odd,well should call it a day.

Verwijzingen naar boeken/films/muziek:

//too much log will kill you

//psycho killer

//qu'est-ce que c'est

int mask = 0xfafafafa;

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

!--0101010001101000011001010111001001100101001000000110100101110011001000000110111001101111001000000111001101110000011011110110111101101110 --

mov si, pCard ; captain?

//Attempt Handshake: Hello? This is London calling. Are we reaching you?

//Handshake Failed: I don't understand...he just hung up.

long john; // silver

#Avert your eyes children, it may take on other forms!

In een ~destructor:

// Choose! Choose the form of the Destructor!

// The choice is made! The Traveler has come!

// batmon.c drives the rastamobile

#What do you think you're doing, Dave?


* For the brave souls who get this far: You are the chosen ones,

* the valiant knights of programming who toil away, without rest,

* fixing our most awful code. To you, true saviors, kings of men,

* I say this: never gonna give you up, never gonna let you down,

* never gonna run around and desert you. Never gonna make you cry,

* never gonna say goodbye. Never gonna tell a lie and hurt you.



//If you're reading this, that means you have been put in charge of my previous project.

//I am so, so sorry for you. God speed.


The winter has come. Here I am, after 9 months of agony still modifying, writing crappy implementations, and adding more shit to a pile of horse poo that's been absorbing everything I've been throwing at it. And it's still hungry...

In my defence, I've tried everything from pitching to the board the necessity of throwing away this pile of junk, to getting an O.K to re-write portions of this monster, to expanding the development team, to do a refactoring sprint, code review sessions, but in vain...

Here I am, desperatly copy-pasting my own code, the ugliest code I've written throughout my 10 years of software development. The most disturbing use of methods, and the most disgusting implementation of OOP standards and more.

All hope is gone, and I'm left with no choice but to fight my way through crappy business requierements and a lousy decision making process to write what's not writeable only to meet illogical deadlines...

I apologize fellow developer for if you reached this place, you're in my shoes now and probably cursing whoever gave birth to this ugly monster.

I apologize fellow developer for you are thinking at this point in time that we're a bunch of retards who know shit about proper software development principles and standards.

I apologize fellow warrior for you are having to read this mind boggling pile of junk, that's been written with the utmost feelings of depression and dispair.

I was once a great developer, but not anymore. Now I'm very much capable of writing a whole 600 page book on "How NOT to write enterprise software" also another book on "How to abuse your machine". This code has taken the lives of at least 3 or 4 computers during the development process. They just couldn't handle the suffering anymore. The pain was to much for them. They had to end it in a way or another...

I wish you the best of luck on your journey to come. It starts with feelings of rage and anger that briefly turn into motivation to fix whatever is fucked. But don't have high hopes my friend, I've been in your shoes... Soon it will all fade away and all you would be doing is appending to this comment

with your story of pain and sorrow.

The night of 14/11/2012 3:45 AM


"This code makes baby Jesus very sad!".

//This code sucks, you know it and I know it.

//Move on and call me an idiot later.

// I dedicate all this code, all my work, to my wife, Darlene, who will

// have to support me and our three children and the dog once it gets

// released into the public.

//For the sins I am about to commit, may James Gosling forgive me

Uit de Linux-kernel:


* Wirzenius wrote this portably, Torvalds fucked it up :-)



* We had N bottles of beer on the wall, we drank one, but now

* there's not N-1 bottles of beer left on the wall...


Dijkstra probably hates me.

In de JavaScript-source:

//We live in a cruel world. Windows XP is over a decade old and yet

//some organizations (including hospitals!) still use it along with

//an ancient form of Internet Explorer, or Firefox 2, etc.

//Fuck those people. Seriously. It's 2012. Download a new browser.

//And while you're at it learn how Facebook privacy settings work.

Overige klassiekers:

/* Genesis, 1. God created the programmer. He saw he was smart and bright, so, in order to stimulate him and make him happy, God created the computer. Both were living in perfect symbiosis and harmony. But then the devil, disguised as a nerd owning a multi-million, closed-source software company, tempted both by hissing in their hears: 'where do you want to go today?' And they committed the original sin, and God wanted to punish them both, so He plunged His hand in the mud and moulded the end user. */

*/Replaces with spaces the braces in cases where braces in places cause stasis */

//Always code as if the guy who ends up maintaining your code

//will be a violent psychopath who knows where you live.

/* ...and don't just declare it volatile and think you've solved

* the problem. You young punks think you know what volatile

* means... why in my day we had to cast it volatile uphill

* both ways, and the code still didn't work! Whippersnappers.../


/* deep wizardry. do not touch. */

/* */

/* no seriously. XXXXXX I'm looking at you. If you screw with this again */

/* I will kill you with my swingline stapler. */

/* */

/* ... */

//somedev1 - 6/7/02 Adding temporary tracking of Login screen

//somedev2 - 5/22/07 Temporary my ass

//To understand recursion, see the bottom of this file


//To understand recursion, see the top of this file

//If this code works, it was written by Paul DiLascia.

//If not, I don't know who wrote it


* Dear Richard Stallman,


* This one's for you.


* Sincerely,

* Me




!pnt_odel //Does anyone read all these comments?

save.block() //Richard does!

Overige grappen
/*  Copyright (c) 

* All rights reserved.


* This program is licensed under the Chicken Dance License v0.2


* You should have received a copy of the license text with this

* software, along with instructions on how to perform the Chicken

* Dance.


Waarbij deze XKCD van Randall Monroe uiteraard niet mag ontbreken:

En als laatste dit advies:

//nobody read comments!