YX Problem(sicpers.info) |
YX Problem(sicpers.info) |
Also a few other takes based on that comment.
https://csf.github.io/blog/2018/05/01/the-yx-problem/
https://yxproblem.wordpress.com/ (SEO ad farming page?)
If you ever help someone in that situation, know that you are a hero among programmers.
the commenter was (unfortunately, inevitably) shat on by a large number of people but it saved me from giving up on tech to live in a cave the rest of my days.
all I could really do was comment with my thanks but that still felt wholly inadequate.
Right, they said "What would you call [it], the YX Problem?"
Is there a meaningful difference as far as coining a term?
The idea of "what if this phenomenon happens in reverse" existed, but adding a name isn't nothing.
This is “What is the XY problem” on Meta-StackExchange from 2010:
https://meta.stackexchange.com/questions/66377/what-is-the-x...
The top answer links to this wiki page that goes back to 2006:
https://mywiki.wooledge.org/XyProblem
First revision here:
https://mywiki.wooledge.org/XyProblem?action=diff&rev1=1&rev...
But realistically, any kind of programming Q&A forum is absolutely flooded with beginners and dolts and literal children, so if you've somehow decided to be a power user that answers a million questions, it's probably reasonable to assume that they really want Y.
I've lost track of the number of times that I need to X (even though I know Y is an option that is probably better in most circumstances) and had to dig through dozens of "do Y instead" answers before finally finding something helpful. More often than not the original asker actually accepts Y as the answer and thanks the responder, but now the search space for X is polluted with yet another non-answer.
I agree with another commenter downthread—the best response when you think you're looking at an XY problem is to answer both X and Y. That way you can be sure that the naive asker is set on the right path (if they are in fact naive), but you're still logging the answer to X so that searches for it don't become useless.
Exactly.
In similar fashion: duplicate questions are alternative ways how people can find the question. (I.e. Useful for later searchers)
When there is an XY problem, Y might be the better option, but most of the time understanding the solution for X is still very interesting.
Also, if somebody can answer Y, but not X, are they really qualified enough to answer the question?
Quite often the person asking questions is a newcomer and is on the path to making the same newbie mistakes we all made when we started. Knowing what question to ask is half the battle.
I got pulled into HR by a young intern for not answering her stated question and instead suggested she was taking the wrong approach and offered an alternative approach. It was clear to all involved that my assumption was indeed correct but she still took it as a condescending slight. It seemed like to me she was looking for reasons to take offense.
I stopped helping her or other interns after that, let the young’uns figure it out for themselves. I figured my time would be better spent shielding myself from the consequences of the coming competency crisis.
1. The person you tried to help could have taken your suggestions in the spirit intended, rather than leaning on a threatening or insulting interpretation of them.
2. You could structure your response in a way that would make your good intentions clear and make the other person more open to the information and less likely to feel threatened or slighted.
It could even be that, from some reasonable perspective, the other person is 100% to blame for the negative outcome, and still, at the same time, you have the ability to avoid such things in the future by adjusting your approach. It's like defensive driving: I'd rather not have accidents at all, and if it's possible to avoid them, I adjust my driving style accordingly. Regardless of how poorly others drive and how much to blame they'd be for accidents I prevented by being defensive.
That way, we can hopefully get the enjoyment of helping others, and the gratitude of those who are more inclined to be grateful, without the trouble of unintentionally angering those whose response is more... complex.
See also: stalebot, scourge of GitHub.
An article gets posted about X. But the top comment is about Y. People pile on to the easy topic of Y.
Not at all. Usually the person asking has some need and the person answering does not. Seems a bit entitled to complain that the person answering provided the anser they though would best help you instead of the answer you wanted.
Would be nice to see an example with X/Y filled in!
You go to an HVAC forum and post the question. Instead of answering the question (or saying that it doesn't matter where you place it), people instead start lecturing you about how electric heating is very inefficient, and you should instead use a Heat Pump, then give you lots of details about heat pumps which are completely irrelevant to your specific issue.
The XY problem is to get all parties involved in thinking about the actual goal and how to achieve that goal. By presuming you know what the Y is already, you're kinda falling to the XY problem yourself.
Very rarely do we need to, for example, draw a square for the sake of drawing a square, there's usually a larger problem we're trying to solve.
Using this: https://news.ycombinator.com/item?id=10024188 as the example.
None of those responses is actually relevant to solving the XY problem (if it exists). The user wants to draw a square with HTML Canvas. Before suggesting any course of action, we need to know why he wants to do that.
The X answer is a lecture on language theory including the construction and inversion of finite state automata. Absolutely interesting, but a long and dense chapter in a CS textbook with no practical applications.
The Y answer is `grep -v test`
...and here-in lies the problem. It's the hubris that "I am right" that leads people to answer Y instead of X.
Y and X are maybe related, but ultimately, X is empirically what was asked. It's your take that Y is the solution that the asker wants instead of X.
Maybe you are right, sometimes.
It's very unlikely you are always right.
Therefore, it's likely, that sometimes when you do this, you're actually not helping; the answer is X, and your comments about Y are both wrong and unhelpful.
Come on, are you never wrong? We're all wrong sometimes.
At the very least, you can often start answering X (a long partial answer) along with 'and this is why Y is maybe a better solution...'
I suggest that the 'race to be the first answer and get karma for it' is the motivator that drives people to do this on some platforms, rather than any actual desire to help / any actual competence in the question domain / actually knowing what they're talking about in many cases; a partial answer to X is never that time consuming.
...it's just more time consuming than not answering it at all.
> Also, if somebody can answer Y, but not X, are they really qualified enough to answer the question?
Maybe. It could be that there just isn't an answer to X. Or the answer is "you can't", so the author tries to give an answer that is more helpful, in case the asker actually wants Y (it would probably be good to explicitly explain that though). Or maybe there are multiple ways of interpreting X, and the answer interpreted it a different way than you expected.
I think this frequently comes up in the form Well actually the idiomatic way to do this is not X but X'; but X really was needed by OP due to some unstated constraint. (Because why would you state it, especially if you're unaware that you're doing it a remarkably unidiomatic way. You're just asking how to do what you're doing.)
Therefore, before giving an XY-probe response to a question, one should think about the probability that the question hides an XY problem.
If the question is about drawing a square, there's no good reason to assume it's an XY problem. Better to just answer the question.
If the question is about something strange that should never come up in typical applications, maybe you can start XY-probing towards the "real question".
For almost all real world questions a more neutral mix of "Well, you could try ${x} by doing ${xthings} but it might also make sense to do ${y} or other things depending on the ultimate goal" actually gets better results faster than a pure XY or YX approach.
I'm trying to draw a square because I need to draw a button. I'm trying to draw a button because I need the user to be able to click it. I'm trying to make something the user can click so they can use this feature. I'm trying to make this feature so the user can do ... I'm trying to enable the user to do ... so my product can be successful. I'm trying to make the product successful so my company can survive. I'm trying to help my company survive so I can keep getting paid. I'm trying to get paid so I can feed my family. ... It goes on.
The XY problem, at least as I usually see it phrased, implies that there's exactly one problem up the stack that the asker should have asked about. There's not. It's impossible to know how much context would be useful and it depends on how much help the asker wants. Sometimes, I just want to draw a square and don't want help redesigning the feature. Maybe sometimes I _could_ use that kind of feedback. I think what's important is to meet people at the level they've asked the question, and _maybe_ suggest that it might be the wrong level. But so often respondents just obnoxiously insist on redesigning the feature when I just need to draw a square.
If you're actually unsure, then be sure. It's a derivative.
Sure, you'd like to have been dealt a better hand. But you haven't, and dwelling on that won't help anyone.
The problem with this metaphor is that it's easy to describe the contents of a hand. But computer programs are a lot more complex than that, and sometimes it's non-trivial (and possibly NDA violating) to describe why the recommended solution isn't feasible.
It's not just NDAs. A lot of times people are constrained in what they can do for a reason they're not inclined to admit. This is extremely common with office politics or any kind of corruption.
The boss demands X because Y would mean not getting kickbacks from a particular vendor, but she can't tell you this so she has to make up some hogwash. Now you have to go ask someone how to do X, and you know the boss's justification is ridiculous but you also know that you can't list "because the boss has issued a rattlebrained mandate" as the reason in a written communication with your name attached to it, so you have to submit the hogwash as the reason or make up your own.
Then the person answering the question points out that the proffered reason for doing it is absurd, which everybody already knows, but nobody can admit it.
In large organizations this kind of thing happens so often that people become conditioned to not even question it and just follow orders, and then it happens even when there isn't a hidden underlying reason, because there is now a culture of not questioning stupid decisions.
If someone asks, "I've downloaded SUPER SQL EXPLORER PRO how do I connect to prod database so I can add a few columns", then you don't sit back and wait, you take actions fast, including contacting manager and revoking access if needed.
In a less extreme situations, you might have a shared task with quick deadline, and someone else went off to the woods instead of making a working design, increasing load on their teammates.
Often it's not XY, for real.
I mean, I see how "derivative" could be wordplay, but I don't see how "seems" is wordplay.
> Come on, are you never wrong? We're all wrong sometimes.
Whatever you do you'll always be wrong sometimes. Answering Y is usually helpful, that's why people do it.
> I suggest that the 'race to be the first answer and get karma for it' is the motivator that drives people to do this on some platforms, rather than any actual desire to help / any actual competence in the question domain / actually knowing what they're talking about in many cases;
This is, if anything, even more true of people who answer the literal question asked while giving no thought as to what the questioner actually wants.
> a partial answer to X is never that time consuming.
Disagree. Often X really is something possible-but-difficult; you can give a "partial answer" in the sense of "I'll need a research team and five years", but that doesn't really help anyone.
If "I'll need a research team and five years" is actually a valid answer to X (eg: X="How do I determine if a given jpeg image contains a bird?", at least... uh, five years ago), then it's a valid answer for the purposes of answering both X and Y. The problem is people giving incorrect/non-answers like "you shouldn't do that", and then pretending they answered the question because they also gave a (presumed for the sake of argument to be correct) answer to some different question, Y.
That's just opinion. :)
The indisputable fact is that it is sometimes unhelpful and wrong.
Is it more harmful to be partially wrong in answering/trying to answer a difficult question, or wrong about helping at all?
Still, on the bright side with the rise of AI helpers, most people don't need anyone to answer trivial questions going forwards, and actually, it becomes (opinion, mine) increasingly clear that answering hard questions is significantly more valuable in a post-AI world.
/shrug
I think, most of the time, answering hard questions is actually not as hard as people imagine them to be.
The answer is usually either 'that's not possible because of blah' (eg. platform restriction) or 'doing it that way is hard because of blah, but if you wanted to, you would look up these things to do it'.
...but often people are too lazy to add that to their answers.
5 years is total utter hyperbole. Obviously.
Spend 10 minutes trying to answer X before you say 'do Y'. 10 minutes. It's such a tiny investment of time, you're just being lazy if you don't.
Well sure, but do you actually disagree? IMO a lot of people are overthinking this and skipping the obvious explanation.
> The indisputable fact is that it is sometimes unhelpful and wrong.
Everyone, and every answering strategy, is "sometimes unhelpful and wrong". (So are AI helpers). So that's not a useful way to compare approaches.
She went on to accuse a bunch of other people of some other nonsense so it was really a matter of time rather than the manner in which I answered questions.
In the highly likely case where your answers are crap, the world is spared yet another person who thinks they are well-suited to add to the mess. In the equally possible case where your answers are not crap, you are spared having to deal with people who cannot appreciate your campaign medals.
nosplaining is great. Welcome to how most of us live.
I think there is a natural impulse to want to help others but there has been a shift of dynamic where the flood of newbs with their entitlement and hostility to those helping them has pushed knowledgeable and helpful people away. And now the newbs can only talk to each other where they can reinforce each others ignorance with the false perception that what they know is correct because they perceive it to be the consensus.
The suggested requirement to avoid the microaggression is to answer both X and Y even when most likely X is irrelevant on the off chance that it isn't. According to some I'm not even allowed to XY probe and must answer both aspects in full to avoid offence. Sure; let me do more free work for you. I used to have some of my code available as open source but got sick of the barrage of questions by those who fail to do even the modicum of effort to understand what they're doing and then get mad at you when you don't provide the exact worked solution to their problem.
People no longer fail to learn, other people have failed to teach them. It's a complete abandonment of personal responsibility. Sure, at this stage I'm shouting into the wind but I think things are going to get really bad really quickly and I feel sorry for those who will have to endure the consequences.
To be helpful and educational, one must describe/illustrate the failure mode of X. For example just demonstrate how unwieldy pure regex is for more constrained question like “regex to check if there is no ‘ab’ within 3 char string”. “a[^ab].|.a[^b]|[^a][^a].”. (Solution complexity grows with length of the string within which we are searching)
No it doesn't. It's something like '([^a]|a[^b]|a$)*'.
In general it scales like '([^a]|a([^b]|$)|ab([^c]|$)|abc([^d]|$)|...)*' (ie, quadratically with the length of the needle, if I haven't overlooked a optimization), but the complement of a regular language is regular, and fixed strings are always regular, so it's always a pure regular expression (including being independent of haystack length).
And, proving that any curt correction of a silly error will likely contain its own silly error, I think that should actually be '^([^a]|a[^b]|a$)*$', since grep defaults to searching rather than matching.
Good to know that there was no repealment for Cunningham’s law.
I’m laughing because I had this exact XY problem. Searched StackExchange for a potential workaround for a certain regex I wanted to match, and the answer said to use Perl regexes instead. Cool... except as far as I can’t tell the database we use doesn’t support that. I rolled my eyes and went to look at other search results.
I don't think the suggested "requirement" (?) to avoid microagression is to answer both X and Y. I think the suggestion to avoid microagression is to avoid using the term microagression in the first place.
Another one would be to recognize that you are fully within your rights to not offer help where it's not your job to offer help. No one cares if you choose not to answer support requests for your open source project, nor will the world suffer for it.
On the flip side, you can't expect those you do help to care enough to show you respect for your help either. If being respected and/or people making special allowances for your tone is something you do care about, well, then don't help to begin with. Contrary to our self-centered worries, the world will go on fine without us. It might even go on better without us; who is to say, after all? Most certainly not us.
Here's a piece of advice I keep hearing from people who are more powerful than me (Usually, these were also people older than me, but that is becoming less true as I grow older myself.): you're owed absolutely nothing. No one is.
Most human beings on this planet live in full awareness of that fact. So its only a matter of time until those who don't, end up learning that too.
Lol, meta-microaggressions that'll fix microaggressions.
I'm aware I'm within my rights to keep quiet and have stated as much. HN is the last place I continue to post and eventually I will stop posting here as well. I do this for my own sake, I live in a cloistered environment protected by wealth, and others who are similarly wealthy, where it continues to remain the 1990s. I engage with people outside of my environment to help myself better understand the cultural phenomenons I see occurring around the world, make a few statements for posterity, and perhaps let some people know it wasn't always like this.
"So its only a matter of time until those who don't, end up learning that too." - yes you will win, but what are you winning really. If future generations cannot learn enough quickly enough in order to produce sufficient value to support their lifestyles then why would they remain entitled to a future brighter than those from 3rd world countries who are quickly catching up with the knowledge work. How do they expect expected to stay ahead of AI. The 1st world middle class is going to be sacrificed on the altar of financialization - I see young people clinging to hope that the specter of communism will come and save them. They can't all be commissars and baristas - someone has to man the work labor camps.
Anyway, are two different things.
> "Lol, meta-microaggressions that'll fix microaggressions."
I have no clue what this means. Do you?
> "yes, you will win..."
What? This isn't "me", winning. This is the age-old reality of "you are owed absolutely nothing", and that "if you are owed something, you will know because people will be paying you for it". This is capitalism at its core.
When it comes specifically to helping others:
1) you are either paid for it by an employer, in which case you ought to do it based on the employer's requirements, and all extraneous complaints are null and void unless
2) you create your own business off of your expertise, where you get to choose what precisely you offer people, and people get to choose whether they value your expertise; or
3) you do it for free, because you get something out of the experience which is entirely unrelated to how others treat you. If you're doing it for free to establish yourself through "loss-leader" tactics, but you cannot turn your losses into said leadership, then you can't complain. The world considers you to be an overvalued commodity. End of story.
Welcome to reality! You can rage if you'd like. The world will not care. There's business to do, money to be made, and entertainment to be had in the form of people who think they are worth more than what the market prices them. Either they are right and they eventually get movies made out of their life stories ("rags to riches!"), or they are wrong and they serve as living comedy (which can also be converted into money).
This is hardcore Reaganomics I am suggesting, not "youth-communism" (lol, wtf? where does that even come from...). Either you are rich enough to earn respect, or you are sensible enough to know you're not worth any. Which one is it?
If you believe you can be rich enough to be shown respect, then why are you wasting your time commenting on HN, instead of turning the apparent coming-doom into a business opportunity? The wealth you earn this way can then be convert into concrete respect if you so choose?
Mentoring is force multiplier in virtualy all scenarios, but there is a fraction of people who are self starting eager readers, that will manage to get out of the newbie stage on their own (as long as they are not actively sabotaged).
Btw. You sound overburned. Btw2. I find being selective of whom to help, very healthy for me.
Even if it's wrong, it'll still be helpful to see an attempt at answering both the question and your interpretation of a solution to the problem.
Only an incorrect and wrong attempt to answer an imagined problem (ie. Y) is actually useless.