this post was submitted on 01 Oct 2023
304 points (96.1% liked)

Programmer Humor

32000 readers
1744 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 

The audacity to do such a thing…

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 24 points 11 months ago (2 children)

Would one not just use a dict/hashmap with int keys labelling lengths and the list of strings as the values?

[–] [email protected] 24 points 11 months ago* (last edited 11 months ago) (1 children)

A programmer might, as trained/conditioned by the limits of programming languages.

A human would intuitively not, these are meaningless and/or convoluted concepts to the untrained human.

[–] [email protected] 10 points 11 months ago

I like the implication that programmers aren't humans, but a sort of alien being naturally apt at algorithmic thinking, while puny humans are an irrational species that needs to undergo training from the mighty race of programmers if they hope to get into the field brought us here by the aliens

[–] [email protected] 3 points 11 months ago (3 children)
[–] [email protected] 4 points 11 months ago

I did use 'list' and forgot it is called an 'array' or 'vector' in other languages. So sure, close enough :-)

[–] [email protected] 3 points 11 months ago

'List' is the correct abstract term for any data structure that holds a given number of values in an order, regardless of the implementation. So Python's List, or C++'s Array or Vector, or a Linked List are all considered lists in the abstract sense.

[–] [email protected] 2 points 11 months ago

Because those are limited to Python? 😜