4

Sorry for the title, but I couldn't think of a good one. Feel free to edit it.

In run haskell operations in parallel or multithreaded, someone asked to speed up computation in Haskell via concurrent/parallel programming. However, a later revision added a second question:

PS: Also, if possible, some optimisations for improving the speed of the operations, because at this point if I run this operation for an interval such as [100..10000] it takes a long time (I stopped it after 45mins).

Since there was already an adequate answer for parallelism/concurrency, I gave an answer that focused on non-concurrent/-parallelism based optimization, although that answer was probably slightly off-topic for the overall context.*

The OP has tried those optimizations and deleted the PS, and instead asked a new question (improve function performance) which solely asks about optimization, in order to benefit me:

Already answered at: https://stackoverflow.com/a/24888322/2008899 – Boyd Stephen Smith Jr. 1 hour ago

I know, I made this so I can accept that other answer – rolandjitsu 1 hour ago

A question written especially for a single user/answer makes me a little uncomfortable, and I totally concur with Cary Swoveland:

This is an unusual situation.

This leads to my following questions:

  1. Should the new question get closed as duplicate? After all, one of them is explicitly asking for concurrency/parallelism compared to ruby, while the other is asking for optimization. They are similar, but not really duplicates.
  2. If the question shouldn't get closed, should I delete my answer on the original question and repost it on the new question? This seems a little bit weird. Can an answer get moved, together with the revision log? (I don't care about the upvotes, so they could get removed in this case, if there's a concern about that)

There's also an additional question, whether my answer, although probably helpful, is actually on-topic on the original question, with the PS being gone, but that's just a sidenote.

* yeah, I realize I should have commented on the question and tell OP that he should ask a new question instead of adding questions into his original one, but I didn't pay attention on the revision log :/

5
  • The bigger problem here is that, "here is some code, optimize plz" is way too broad of a question for SO.
    – Servy
    Commented Jul 23, 2014 at 18:57
  • @Servy: Hm, that's also true. There's some difference between "plz optimize" and "why is my code running so slow". Noted.
    – Zeta
    Commented Jul 23, 2014 at 18:59
  • I think that captures the essence of the question...
    – user1228
    Commented Jul 23, 2014 at 19:11
  • 1
    Despite the second question possibly off-topic, the person actually did the right thing to ask a second question for another problem. Yes you might have already provided an answer but with the new question, other will see it clearly and might provide a even better answer than yours. Commented Jul 23, 2014 at 19:12
  • 2
    BTW, without considering the quality of the questions, splitting up a multiquestion into individual ones is fine in my book.
    – user1228
    Commented Jul 23, 2014 at 19:12

1 Answer 1

5

It's not appropriate to edit an entirely new question into an existing question. If the author of a question has a new question they need to ask a new question.

If you see someone edit an entirely new question into an existing question you should roll back the edit and tell them to ask a new question if they have a new question, you shouldn't answer it.

If there is a question with a second question edited into it and an answer to the second question it's still appropriate to try to clean this up by asking the second question as a new question, deleting the answer, and posting the answer to the appropriate question.

Having said all of that, this question doesn't seem particularly appropriate for an SO question. Just asking how to optimize a block of code is a very broad question, which isn't well suited to SO's model.

4
  • Shouldn't this kind of optimization questions be asked on Code Review instead ?
    – Autar
    Commented Jul 24, 2014 at 7:46
  • @Autar It may be appropriate on CR; not being active there I couldn't say if it would meet their guidelines
    – Servy
    Commented Jul 24, 2014 at 14:03
  • I'm not really active on it either but I think it matches the description from this question : "CodeReview: Your code works but you'd love to hear how it could work better"
    – Autar
    Commented Jul 24, 2014 at 14:58
  • @Autar I know enough to know that they have a number of strict guidelines. I don't know them well enough to speak to whether or not this meets all of them.
    – Servy
    Commented Jul 24, 2014 at 15:00

You must log in to answer this question.

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