Search CTRL + K

X-Y Problem

XY 问题(x-y problem) 是指提问者本意是解决 X 问题,自认为 Y 是解决办法,于是询问 Y 问题如何做,事实上解决 X 问题有更合适的方案,导致在错误的方向上浪费大量时间精力。

为了避免 XY 问题,在提问时尽可能带上更多信息,特别是被排除的方案,带上排除的具体原因。

What is X-Y Problem?

The X-Y Problem, as it is sometimes called, occurs when a person tries to solve a problem on their own, pursues a method that seems like a promising approach, gets stuck, and then asks for help with their chosen method (instead of asking for help with the original problem).

In reality, the method on which they got stuck may be the longest/most complicated route to the answer. The best way to solve the problem is to start over.

In other words:

  • User wants to do X.
  • User doesn't know how to do X, but thinks they can fumble their way to a solution if they can just manage to do Y.
  • User doesn't know how to do Y either.
  • User asks for help with Y.
  • Others try to help user with Y, but are confused because Y seems like a strange problem to want to solve.
  • After much interaction and wasted time, it finally becomes clear that the user really wants help with X, and that Y was a dead end.

The reason people get their train of thought stuck on one approach is that they've forgotten how much they rely on trial and error problem solving shortcuts so they're valuing a potential dead end just as if it were a proven thing. Remaining open to having a new look at the bigger picture, might help such people to accept just being handed the solution to X instead, be directed to alternatives which might be more practical by far, or being assured that the particular approach they've been working on doing is unsuitable.[1]

Re: How do I keep the command line from eating the backslashes?

This feels like an XY problem. You're trying to do X, and you thought of solution Y. So you're asking about solution Y, without even mentioning X (your later posts hint at X, but never really describe it). The problem is, there might be a better solution, but we can't know that unless you describe what X is.[2]

Re: Re: Re: Re: regex to validate e-mail addresses and phone numbers

Have you ever heard of an XY problem? It is when someone asks how to do Y when they really want to do X. They ask how to do Y because they believe it is the best way to accomplish X. The people that they ask go through many iterations of "try this", followed by "that won't work because of". I am not suggesting to use something other than Email::Valid if that truly is what is desired. What I am saying that is depending on the circumstance, other solutions may be the way to go.[3]

How to avoid X-Y Problem?

To avoid falling into this trap, always include information about a broader picture along with any attempted solution. If someone asks for more information, or especially a more specific question, do provide details. If there are other solutions which you believe will be suggested and which you've already ruled out, then don't try to avoid going over them again – instead state why you've ruled them out, as this gives more information about your requirements and helps others provide better answers.[4]

  1. ↩︎

  2. ↩︎

  3. ↩︎

  4. ↩︎