3 ms·
You can write a list data structure with performant 'delete' properties if you're willing to maintain a sort or a hash table. There would be people here bitchin
by jholloway7 6y ago
You can write a list data structure with performant 'delete' properties if you're willing to maintain a sort or a hash table. There would be people here bitching about memory usage if the stdlib did that natively. Here's a solution: don't use list.delete. You're using the wrong data structure if that's your solution to whatever collection you're maintaining.
- jholloway7 6y agoDownvotes on comp sci 102. Nice.
- mirekrusin 6y agoWe have this saying in my country "if grandma had a mustache she'd be a grandpa".
- omaranto 6y agoI like my country's version better: "if grandma had wheels she'd be a bicycle".
- jholloway7 6y agoIf your aunt had nuts she'd be your uncle
- omaranto 6y agoThat has the same basic idea as the mustache version, but is pithier. I still prefer the surrealism of the bicycle.
- arp242 6y agoWhich language/country is this? I will use this in English regardless. I like it.
- omaranto 6y agoMexican Spanish. I don't know if they also use that saying in other Spanish speaking countries besides Mexico. In Spanish it goes: "Si mi abuelita tuviera ruedas, sería bicicleta".
- code_duck 6y agoYou'd probably do better on HN to substitute 'decrying' for 'bitching'.
- jholloway7 6y agoNoted, thanks. Didn't realize that was the issue.