this post was submitted on 03 Jun 2023
62 points (100.0% liked)

Memes

1357 readers
23 users here now

Rules:

  1. Be civil and nice.
  2. Try not to excessively repost, as a rule of thumb, wait at least 2 months to do it if you have to.

founded 5 years ago
MODERATORS
 

I saw a post from someone wanting more trans memes and took that as a sign to post one of mine.

top 18 comments
sorted by: hot top controversial new old
[–] SubArcticTundra 15 points 2 years ago

Nah fam Rust has you covered:

enum Gender {
  Male,
  Female,
  Other(str&),
};

That said my Rust knowledge is shit

[–] XPost3000@lemmy.ml 13 points 2 years ago (1 children)

"Please Input Your Gender": Girl' ; DROP TABLE GENDERS

[–] D-ISS-O-CIA-TED@kbin.social 1 points 1 year ago

I will never not laugh at this joke, it's so sudden and unexpected. And the all caps is so "loud". I love it :)

[–] ryuko@lemmy.ml 7 points 2 years ago

Can we store gender on a quantum computer? Quibits.

[–] Hexorg 6 points 2 years ago (1 children)

Shouldn’t it be a float?

[–] a_random_fox@lemmy.ml 3 points 2 years ago (1 children)

I don't think so, but i would like to hear why a float would be better. Might change my opinion.

[–] magmaus3@szmer.info 2 points 2 years ago (1 children)

I think the reason why is because a float would be easier to store, while having enough possibilities for such data.

[–] borari@lemmy.ml 3 points 2 years ago

Is there some array that links a specific float value to a gender? Storing something like that as a float and having to look it up outside the object itself to determine it’s actual value seems like bad practice to mezcal but I’m not a developer by trade.

[–] DAT@feddit.de 4 points 2 years ago (1 children)

why have to store it as data at all?

[–] Biscuit@kbin.social 2 points 1 year ago

How else will they know how to spend their ad dollars!?

[–] biscuitsofdeath@lemmy.ml 4 points 2 years ago

Just call the variable isGender

[–] _cnt0@feddit.de 4 points 2 years ago (1 children)

Strings are messy. I'm in favor of some covoluted struct or union.

[–] Biscuit@kbin.social 1 points 1 year ago

They’re also too static. Need a user provided script to handle things like gender fluid.

[–] midas@ymmel.nl 2 points 1 year ago

In the app I'm building contacts have an Enum Sex (Male, Female, Unknown) and an Integer Gender which is a foreign key to gender table

[–] MinekPo1@lemmy.ml 2 points 2 years ago (1 children)

:3 thanx. Hav headpats (if you wan ofc)

[–] a_random_fox@lemmy.ml 2 points 2 years ago

Thanks for the headpats

[–] sussy_gussy@wirebase.org 2 points 1 year ago

3d vector gender

[–] TofuSauce 1 points 2 years ago
load more comments
view more: next ›