I had a programming test where was asked to do a particular problem. However, there was some kind of mistake in a problem as I was able to see that there can't be particular type of inputs for the function. Is the correct way to answer the question something like "By working over the field Z/9Z we see that there is no inputs of the given form" or "Let us modify the problem a bit and remove that condition. Then the following algorithm will do the job."?

  • 17
    Not an answer, but frankly, when I interview, someone who can spot an issue in a posed problem instantly gets 100+ cookie points over merely solving a correct problem. It means I can rely on them to spot check/backstop me when we are on the same team.
    – user13655
    Aug 31, 2014 at 0:40
  • I can't tell from your question if the answer with Z/9Z (are you sure this is a field?!) is a "smart-ass answer" or something related to the work. I would definitely avoid answering: "What is the next number: 2,4,6,..." with "Mathematically, there is no real answer, one could say e.g 32 because consider the following weird function .."
    – guest
    Jul 7, 2020 at 20:21

2 Answers 2


Why not do both? Explain the issue that keeps you from completing the exercise as it's written, and then provide an alternate approach that gives the same results. This will show that you understand the problem domain, and that you're experienced and flexible enough to determine the root cause and provide another solution.


It is entirely possible that spotting the problem with the problem was the real test. They acknowledge that at times instructions from management have mistakes in them and they want to know how you deal with it.

It's known that at some companies the interview process will test you and evaluate you in ways that aren't made obvious at the start. If there is a wait until your interviewer shows up, and you are sent to the break room, the guy who walks in and starts a conversation with you could be an interviewer.

In fact, everyone you deal with on company property could be part of the interview process. In one case I know of, a US Air Force pilot was being interviewed by an airline. They flew him first class to the interview site, and he was able to enjoy the benefits of first class service on this flight.

The formal interview opened with this question: "Do you always drink that much?"

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .