In this algorithms question, I asked how to solve an algorithms question from a book, which I later realised I completely misread. The question I asked still led to some interesting discussion, but I don't think that it is possible to solve. As per the question in the book, you are in fact meant to return a new array, and not modify the original one.

One of the commenters called Vince, gave an answer which with slight modification, would have been correct had I specified the question correctly. I incorporated this answer into my question as an example of an insufficient solution alongside my own one, which had difference complexity characteristics. The comments which I took Vince's answer from seem to have disappeared.

In light of my error, I am now wondering how to proceed. Should I rename the question and correct it, posting Vince's now correct solution, or should the question just be deleted?

| |

There is no soon to be invalidated answer, so you can do as you wish, but with interesting problem it would be a waste to delete it.

There are ways that seem plausible:

  • modify question and notify Vince
  • modify question and answer yourself
  • if modification greatly affects question, you could ask separate one
| |
  • $\begingroup$ I would like to modify it to the correct question and post Vince's answer. Vince has removed his comments, so should I mention that the answer was written by an anonymous user? $\endgroup$ – justinpc Feb 11 '19 at 21:22
  • $\begingroup$ @jpcooper He is not anonymous, mayhap mention by name or just drop it, answer on its own is for future users. $\endgroup$ – Evil Feb 11 '19 at 21:33

You must log in to answer this question.

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