Representative line: int gender



  • Without checking, anyone care to guess what number represents males and what represents females?

    (I called this representative line, but this is actual a representative seventeen lines. Sorry. Code is unchanged.)

                                        int gender = 0;
    
                                    gender = (!person.IsMale).GetHashCode();
    

  • Discourse touched me in a no-no place

    TRWTF are all those blank lines…



  • I don't see the WTF here, this looks like a forward-thinking developer.

    • What if humans genetically modify new genders? We must be prepared for all possibilities.
    • The number of whitespace lines between pieces of code has grown over the years. This is just adapting to the future.
    • If the hash were not taken for this, how would we assign a value? Do we just arbitrarily assign a number to the first genders that come up? Maybe 0 for male and 1 for female? Isn't that sexist?

    Am I correct the language automatically casts to integer, or is the hash code returned already of an integer value? I'm just curious because the syntax looks common to many languages (though I would guess at Java).

    So to answer your question I don't know. :P


  • Discourse touched me in a no-no place

    @Shoreline said:

    Am I correct the language automatically casts to integer, or is the hash code returned already of an integer value? I'm just curious because the syntax looks common to many languages (though I would guess at Java).
    More likely C#, given the capitalization of the methods.



  • @Shoreline said:

    Am I correct the language automatically casts to integer, or is the hash code returned already of an integer value? I'm just curious because the syntax looks common to many languages (though I would guess at Java).

    The return value is an integer.



  • Is it a bitfield where bit 0 is the current mental gender, bit 1 is the current physological gender and bit 2 is the birth gender?



  • @henke37 said:

    Is it a bitfield where bit 0 is the current mental gender, bit 1 is the current physological gender and bit 2 is the birth gender?

    Are you suggesting that gender can be represented with a single bit? That's offensive! What about bigenders, trigenders, pangenders, third genders, nongendereds and genderfluids?



  • @spamcourt said:

    genderfluids
     

    Sexy.



  • @spamcourt said:

    What about bigenders, trigenders, pangenders, third genders, nongendereds and genderfluids?

    #define MALE 0
    #define FEMALE 1
    #define BIGENDER 1
    #define TRIGENDER 1
    #define PANGENDER 1
    #define THIRD_GENDER 1
    #define NONGENDER 1
    #define GENDERFLUID 1
    #define OTHER 1
    

    All in a single bit.



  • Male is one, Female is zero. They are pictograms, http://en.wikipedia.org/wiki/Pictogram.

    Duh



  • @henke37 said:

    Is it a bitfield where bit 0 is the current mental gender, bit 1 is the current physological gender and bit 2 is the birth gender?
    Everyone seems to be making the same mistake here.  Sex is biological, physiological, maybe psychological, societal, etc;

    Gender, however, is grammatical.



  • @da Doctah said:

    @henke37 said:

    Is it a bitfield where bit 0 is the current mental gender, bit 1 is the current physological gender and bit 2 is the birth gender?
    Everyone seems to be making the same mistake here.  Sex is biological, physiological, maybe psychological, societal, etc;

    Gender, however, is grammatical.


    Maybe the code is from some kind of text generator? Or the developer was afraid to get sued for sexual harassment for naming a variable "sex".



  • @da Doctah said:

    @henke37 said:

    Is it a bitfield where bit 0 is the current mental gender, bit 1 is the current physological gender and bit 2 is the birth gender?
    Everyone seems to be making the same mistake here.  Sex is biological, physiological, maybe psychological, societal, etc;

    Gender, however, is grammatical.

     

    Thus, there are three of them. (In English, it varies with language.)

     



  • @Mcoder said:

    @da Doctah said:

    Gender, however, is grammatical.

     

    Thus, there are three of them. (In English, it varies with language.)

     

    One in some languages (as in English, apart from personal pronouns), two in others (where there is no "neuter"), the traditional three in others, and in a few special cases, more than three (I believe there are languages where working animals are in one grammatical category, wild animals in another, inanimate objects fall into several classes depending upon what they're used for, children who are too young to talk a special gender all their own, etc).

     



  • @da Doctah said:

    I believe there are languages where working animals are in one grammatical category, wild animals in another, inanimate objects fall into several classes depending upon what they're used for, children who are too young to talk a special gender all their own, etc

    Let me guess. Japanese?



  •  We have a number of genders available by default (medical software).  Male, Female, Unknown, Other, and Refused to Specify.  There are actually good reasons (for us) to do a similar (yet less WTF-y) "not-male" check.  Any gender except male shows warnings about requiring pregnancy tests before certain procedures, for example.



  • type Gender struct {
    LooksLikeABitch bool
    HasADick bool
    CapableOfReproducing bool
    YChromosome bool
    HasLadyParts bool
    Breasts int64
    }



  •  @ekolis said:

    Let me guess. Japanese?

    Nope. No gender at all in Japanese (grammatically, that is).



  •  At work, we have the genders (that's at least what we call them) MALE, FEMALE and UNKNOWN. But the latter is for when we don't know, not when the customer isn't quite sure him/her/itself.



  • @Severity One said:

     At work, we have the genders (that's at least what we call them) MALE, FEMALE and UNKNOWN. But the latter is for when we don't know, not when the customer isn't quite sure him/her/itself.

    That's TRWTF. Obviously it should be MALE, FEMALE, and FILE_NOT_FOUND.



  • Clearly, a boolean just won't be enough, you need that int to be able to represent something like 5 separate genders. Maybe an enum...?



  • @Ben L. said:

    Breasts int64
     

    wait



  • @derari said:

    genderual harbuttment

     

    @Ben L. said:

    Breasts int64
    And what if the person has only one breast? Better generalize:

    [quote user=""]Breasts ICollection<int64>[/quote] 



  • @Zecc said:

    @derari said:

    genderual harbuttment

     

    @Ben L. said:

    Breasts int64
    And what if the person has only one breast? Better generalize:

    [quote user=""]Breasts ICollection<int64>

     

    [/quote]

    For some reason, I thought he was specifying quantity of breasts, not size. Which made the signed int even funnier.

    Really, though, breasts need to be their own struct. There are so many properties that need to be painstakingly measured..



  • @Ben L. said:

    type Gender struct {
    LooksLikeABitch bool
    HasADick bool
    CapableOfReproducing bool
    YChromosome bool
    HasLadyParts bool
    Breasts int64
    }

    Here's 80% of the people on TDWTF:

    { true, true, false, true, true, Int64.MaxValue }


  • Discourse touched me in a no-no place

    @Ben L. said:

    type Gender struct {
    LooksLikeMarcellusWallace bool
    HasADick bool
    CapableOfReproducing bool
    YChromosome bool
    HasLadyParts bool
    Breasts int64
    }
    FTFY.



  • @dkf said:

    @Ben L. said:
    type Gender struct {
    LooksLikeMarcellusWallace bool
    HasADick bool
    CapableOfReproducing bool
    YChromosome bool
    HasLadyParts bool
    Breasts int64
    }
    FTFY.

    What?



  • @morbiuswilters said:

    @Ben L. said:
    type Gender struct {
    LooksLikeABitch bool
    HasADick bool
    CapableOfReproducing bool
    YChromosome bool
    HasLadyParts bool
    Breasts int64
    }

    Here's 80% of the people on TDWTF:

    { true, true, false, true, true, Int64.MaxValue }

    Er... who hacked the account of morbiuswilters, who --AFAWK-- is { true,
    true, certainlyNot, FILE_NOT_FOUND, onlyInThePicture, onlyInYourDreams
    }?



  • @Zemm said:

    What?
     

    Pulp Fiction.



  • @Zemm said:

    What?
     

    ENGLISH, MOTHERFUCKER!

    DO. YOU. SPEAK. IT?



  • When encoding survey data, it is customary to represent sex as a dummy variable that takes on the value of 0 for one of the sexes and 1 for the other so that when you look at the averages you can automatically see the percentage of male vs female respondents (ditto for percent employed, or percent homeowner etc etc).

    I am sure the hash code was really helpful in that regard ;-)

    PS:The real WTF is thinking the word 'gender' is synonymous with 'sex'.



  •  Wait, you gave Breasts an int64, but gave Dick only a boolean? That's not nearly enough to fit any normal-sized dick, or at least not my dick. My dick needs at least a BigDecimal.



  • Don't be so negative, I'm sure it's not that small.



  • @Zecc said:

    And what if the person has only one breast? Better generalize:

    [quote user=""]Breasts ICollection<int64>

     

    [/quote]
    syntax error: unexpected <, expecting semicolon or newline or }

    Silly, silly. For one breast, you set the Breasts field to 1. My system supports as few as -9223372036854775808 or as many as 9223372036854775807 breasts.

    By the way, if you want a slice (variable-length array) of int64s, the syntax is []]int64.

    As for the syntax...



  • @Cassidy said:

    @Zemm said:

    What?
     

    ENGLISH, MOTHERFUCKER!

    DO. YOU. SPEAK. IT?

     

    Oh, ok.  Derp.

     



  • You guys should have a look at the more "imaginative" adventure games.



  • @henke37 said:

    You guys should have a look at the more "imaginative" adventure games.
     

    They should rename that option to "Armor cover:  [x] complete protection [ ] underwear"



  • @dhromed said:

    They should rename that option to "Armor cover:  [x] complete protection [ ] underwear"
     

    But they do! They're called [ ] male and [x] fe ---oooohhhhhh.......!



  • @Cat said:

     We have a number of genders available by default (medical software).  Male, Female, Unknown, Other, and Refused to Specify.  There are actually good reasons (for us) to do a similar (yet less WTF-y) "not-male" check.  Any gender except male shows warnings about requiring pregnancy tests before certain procedures, for example.

    Could you please fix that shit?! It is really annoying to be constantly reminded of the fact that I can't get pregnant. I think it's time for the software to recognize the "Sex=male + gender=female" situation (and the other way around).



  • @jasmine2501 said:

    @Cat said:

     We have a number of genders available by default (medical software).  Male, Female, Unknown, Other, and Refused to Specify.  There are actually good reasons (for us) to do a similar (yet less WTF-y) "not-male" check.  Any gender except male shows warnings about requiring pregnancy tests before certain procedures, for example.

    Could you please fix that shit?! It is really annoying to be constantly reminded of the fact that I can't get pregnant. I think it's time for the software to recognize the "Sex=male + gender=female" situation (and the other way around).

    Yes, let's expend precious healthcare IT resources so the guy who mutilated his dick doesn't have to question the wisdom of that decision. Oh, and do you think you can get my hepatologist to stop asking me if I'm still drinking? It's become a chore to put down my beer, climb out of the MRI and kick his ass.



  • @TGV said:

    @morbiuswilters said:
    @Ben L. said:
    type Gender struct {
    LooksLikeABitch bool
    HasADick bool
    CapableOfReproducing bool
    YChromosome bool
    HasLadyParts bool
    Breasts int64
    }

    Here's 80% of the people on TDWTF:

    { true, true, false, true, true, Int64.MaxValue }

    Er... who hacked the account of morbiuswilters, who --AFAWK-- is { true,
    true, certainlyNot, FILE_NOT_FOUND, onlyInThePicture, onlyInYourDreams
    }?

    For your information, I have two Y chromosomes.



  • @morbiuswilters said:

    For your information, I have two Y chromosomes.
     

    Fucking mammals and your [url="http://en.wikipedia.org/wiki/Z_chromosome"]dumbass chromosomes[/url]



  • @morbiuswilters said:

    Yes, let's expend precious healthcare IT resources so the guy who mutilated his dick doesn't have to question the wisdom of that decision.

    Since this kind of ignorance is prevalent and can only be fixed by waiting for the idiots to die, I think yes, it would be cheaper to fix the software.



  • @jasmine2501 said:

    ignorance
     

    You forget; morbius is troll extraordinaire, producing flammable concepts of exquisite quality.



  • @Lorne Kates said:

    @morbiuswilters said:

    For your information, I have two Y chromosomes.
     

    Fucking mammals and your dumbass chromosomes

    I remember being told in elementary that the fact that the sperm carries the sex-determining chromosome means men can't blame women for the sex of the child, but that's bullshit. I mean, I provided her a massive assortment of Xs and Ys; after that, I don't know what she did with it. But I promise if I end up with another non-Super-Soldier girl she can say goodbye to the 1 hour of daylight I'd been letting into her cell each day.



  • @jasmine2501 said:

    @morbiuswilters said:
    Yes, let's expend precious healthcare IT resources so the guy who mutilated his dick doesn't have to question the wisdom of that decision.

    Since this kind of ignorance is prevalent and can only be fixed by waiting for the idiots to die, I think yes, it would be cheaper to fix the software.

    You can't blame me, I was born this way. You're committing a hate crime. And considering that my condition has yet to be recognized by as many doctors as yours, I'm even more oppressed than you (and isn't that the entire goal here--to see how much sympathy we can milk from people through our ridiculous acting out?) Why are you afraid of what you don't understand? HATE CRIME!



  • @dhromed said:

    @jasmine2501 said:

    ignorance
     

    You forget; morbius is troll extraordinaire, producing flammable concepts of exquisite quality.

    Trollophobe.



  • @dhromed said:

    @jasmine2501 said:

    ignorance
     

    You forget; morbius is troll extraordinaire, producing flammable concepts of exquisite quality.


    Pretty sure he's just an asshole.



  • @spamcourt said:

    @dhromed said:

    @jasmine2501 said:

    ignorance
     

    You forget; morbius is troll extraordinaire, producing flammable concepts of exquisite quality.


    Pretty sure he's just an asshole.

    My doctor says it's a legitimate condition and you have to treat me like I'm normal or else you're a hatemonger.



  • @spamcourt said:

    Pretty sure he's just an asshole.
     

    Yes.


Log in to reply
 

Looks like your connection to What the Daily WTF? was lost, please wait while we try to reconnect.