this post was submitted on 02 Dec 2024
1491 points (99.3% liked)

Memes

8516 readers
335 users here now

Post memes here.

A meme is an idea, behavior, or style that spreads by means of imitation from person to person within a culture and often carries symbolic meaning representing a particular phenomenon or theme.

An Internet meme or meme, is a cultural item that is spread via the Internet, often through social media platforms. The name is by the concept of memes proposed by Richard Dawkins in 1972. Internet memes can take various forms, such as images, videos, GIFs, and various other viral sensations.


Laittakaa meemejä tänne.

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 56 points 3 weeks ago (1 children)

Honestly, this was the comment that exposed me (regular office rube) to binary search as a concept and it is so. fucking. helpful.

[–] [email protected] 9 points 3 weeks ago* (last edited 3 weeks ago) (2 children)

In what ways do you use it in your daily life? Genuinely curious.

[–] [email protected] 22 points 3 weeks ago (1 children)

not the commenter you asked but i use a binary search when i'm playing a modded game that is having issues to pinpoint which mod(s) cause the issue. beats launching the game over and over to test each mod by a long shot.

a recent example: i put together a mod list for risk of rain 2 to play with some friends, but the game crashed on launch when all the mods were installed. so i disabled half the mods (in order, alphabetically or other) and tried to launch the game again - still crashing. disabled half the remaining enabled mods, test, repeated as necessary. with only a few cycles of booting the game, i was able to determine the specific mod causing a crash on startup out of my list of 50 something mods.

[–] [email protected] 9 points 3 weeks ago (1 children)

While that's really cool and useful, it might be the way a couple of mods interact as opposed to a specific one.

[–] [email protected] 6 points 3 weeks ago

Sure, but it'll still narrow down on one of those mods - perfect information would require figuring out why it crashes in the first place, but finding at least one of them would let you play the game without it and look up if anybody else reported problems with that mod.

[–] [email protected] 7 points 3 weeks ago* (last edited 1 week ago) (2 children)

Imagine you work at a company that sells cookies. The company signs a contract offering a customer a set variety of cookies at various prices, with a clause stating that if the customer wants another type of cookie the company makes later on, it will be priced and added to their list. This should be in the form of regular contract amendments/addendums, but it isn't.

Several years go by, and in the course of that several different varieties of cookies have been added by the customer. The price given to them at the time may not account for the cost of materials and labor today, or how many of those cookies not mentioned in the contract are being ordered v. how many were expected, the fact that you outsourced some of those cookies, or brought some of those cookies in-house, etc. The cookie executive asks you "When did we offer customer x cookie y at price point z?"

Now, the company has a perfectly good database of cookies and price points for customers, but it's very old tech and requires certain access privileges, which are very hard to give people outside of the accounting department. Accounting is never able to help with this, and the cookie executives try poorly and fail to get people like you access. But you do have years and years of cookie addition request forms, which are kept in chronological order by customer and contain a list of all types of cookies requested up to that point in time.This is where binary search helps - you can pretty quickly find the one where the cookie y was added even though there are hundreds of these forms.

It's not a situation that should exist - we have a god damn cookie database where you can just pop in customer x and cookie y to get price z, with an effective date - but in my crazy cookie factory it helps a ton.

There's other examples but they're all pretty much variants of this thinly veiled analogy.

[–] [email protected] 1 points 3 weeks ago (1 children)

That doesn't make sense at all. How would you - given two stacks of papers - know which stack the correct form is?

[–] [email protected] 2 points 3 weeks ago* (last edited 3 weeks ago) (1 children)

There's lots of stuff about what I do that doesn't make much sense :)

It works in this scenario because the stacks are reliably sorted by customer and date, and each form has a running tally of what cookies are on offer as things get added to the list.

Assume customer x's forms are taken out, and you make two stacks of them without shuffling the forms. The very first form on the first stack from 2022-01-01 does not include cookie y. The first form on the second stack, from 2023-02-01, also does not contain cookie y. Based on this information and the conditions above, you can infer that the form you want is in the second stack.

Now, if the forms were not reliably sorted, or did not contain a running record, you'd need to approach this differently. Strategies would probably involve inferences or straight getting the info you need from other sources - custumer correspondence around "We want cookie y, how much?" (if it occurred when you were in a position to get such correspondence); knowledge of big changes to cookie offerings to the customer (contract renewals); bugging accounting at a regular, annoying cadence with progressive escalation until they answer/complain about you bugging them, etc.

[–] [email protected] 1 points 3 weeks ago

Wow that got complicated very quickly. Bummer no-one can come up with a simple example of when quicksort is useful.

[–] [email protected] 6 points 3 weeks ago (1 children)

Sometimes that’s just the way the cookie crumbles, man

[–] [email protected] 3 points 3 weeks ago (1 children)

It's a crummy job, but someone's gotta do it.

[–] [email protected] 3 points 3 weeks ago

Slightly irked you didn't spell it "crumby" 😅