Reply
Funny code comments
Old 04-27-2008, 11:42 AM Re: Funny code comments
Gilligan's Avatar
DEAD Good Coder

Posts: 1,151
Name: Stefan
Location: London, UK
lol, i like the phone number
Gilligan is offline
Reply With Quote
View Public Profile
 
Sponsored Links (We share ad revenue):
 
Old 04-28-2008, 05:25 AM Re: Funny code comments
Average Talker

Posts: 23
Name: James
Hey i love this thread, heres mine: this is a python function to classify abundant, defficiant and perfect numbers.
Code:
def classify(n):
    def factors(n):
        result = []
        for i in range(1, n+1):
            if n % i == 0:
                result.append(i)
        return result

    if sum(factors(n)) -n == n:
        print "perfect"
    elif sum(factors(n))-n > n:
        print "abundant"
    elif sum(factors(n))-n < n:
        print "deficiant"
    else:
        print "WTF u moronic twit dont screw around with my program!!!!"
__________________
Visit my webmaster blog:
Dynamik Designz
4o4found is offline
Reply With Quote
View Public Profile
 
Old 04-28-2008, 11:05 AM Re: Funny code comments
Administrator

Posts: 19
Name: LarryB
These are from a windows app I just wrote for another company.

Code:
// we found and existing container
// this should never happen @ config load.
// but since it did happen lets check rules
// shall we.  Can a new instance of this module
// be added to the container?

// oh no.  We didn't get a lock.  that's bad.

// Uh-Oh. There should be a module container. Someone screwed up.
// Blame the architect.

// The module is null?  Oh no.. nothing we can do.
// Call the developer, he/she blundered something.
This is from a web app I wrote last year. Probably one of my favorites.

Code:
// HACK: Larry B**** Approved By: 
// THIS IS THE CODE THAT IDENTIFIES ALL CREDIT
// CARDS.  YET ANOTHER VISCIOUS HACK THAT SHOULD
// BE FIXED IN THE FUTURE.

// Code to hide left column in the case of ***** ******* authentication.
// This is currently a horrible hack.  A better way of doing this should
// probably be devised in the future.  Currently it hides the left column
// div and hides the left column base div.  It also outputs NoLeftColumn
// at the end of the css class declaration of the right column.
// Larry
LarryB is offline
Reply With Quote
View Public Profile
 
Old 04-28-2008, 09:16 PM Re: Funny code comments
Average Talker

Posts: 22
awsome
Havoc is offline
Reply With Quote
View Public Profile
 
Old 04-29-2008, 07:06 AM Re: Funny code comments
Average Talker

Posts: 23
Name: James
lol this is a very funny thread
__________________
Visit my webmaster blog:
Dynamik Designz
4o4found is offline
Reply With Quote
View Public Profile
 
Old 04-30-2008, 08:13 AM Re: Funny code comments
Novice Talker

Posts: 10
funny
bigweeble is offline
Reply With Quote
View Public Profile
 
Old 04-30-2008, 09:03 AM Re: Funny code comments
arcel's Avatar
Ultra Talker

Posts: 408
Name: Topman
hahaha... like the python function code.
arcel is offline
Reply With Quote
View Public Profile
 
Old 05-02-2008, 01:24 PM Re: Funny code comments
nickohrn's Avatar
Weightlifting CS Student

Posts: 496
Name: Nick Ohrn
My favorite funny code comments statistic is the number of swear words present in the Linux kernel at all times. Here's a fancy little graph that shows it: LINK
__________________
NickOhrn.com - My personal haven of insight to offer the world.
Plugin-Developer.com - Custom plugin development to fit your needs. Plugins available for WordPress and Drupal, among others.
nickohrn is offline
Reply With Quote
View Public Profile Visit nickohrn's homepage!
 
Old 05-03-2008, 03:51 PM Re: Funny code comments
wayfarer07's Avatar
Extreme Talker

Posts: 223
Name: Abel Mohler
Location: Asheville, North Carolina USA
Quote:
...the number of swear words present in the Linux kernel at all times...
heh, 'penguin' IS a pretty nasty swear word.
__________________
Go FREELANCE <-----|-----> Hire Me
wayfarer07 is offline
Reply With Quote
View Public Profile
 
Old 05-04-2008, 12:53 AM Re: Funny code comments
pro
Novice Talker

Posts: 9
Lol, freak en hilarious.. I should attempt this later on one of my sites.. How many of you do this?
pro is offline
Reply With Quote
View Public Profile
 
Old 05-04-2008, 02:50 AM Re: Funny code comments
Average Talker

Posts: 15
Name: rowena
Funny things happen, maybe because they do it intentionally just to be recognize, and the viewer will take a second look.
__________________
Nice deals
tish is offline
Reply With Quote
View Public Profile
 
Sponsored Links (We share ad revenue):
 
Reply     « Reply to Funny code comments

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML


Page generated in 0.15967 seconds with 14 queries