this post was submitted on 01 Oct 2023
476 points (96.7% liked)

Programmer Humor

34156 readers
26 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] 13 points 1 year ago

It depends. If the variable names are arbitrary, then a map is best. If the variable names are just x_1, x_2, x_3, ..., x_n, then a list or dynamic array would be more natural. If n is constant, then a vector or static array is even better.