6
$\begingroup$

Here someone asked a question about finding median, with a simple google search "median of unsorted array in O(n)" all first three results are about correct way to do it. But there is no policy to close questions without any effort (for this site).

I don't know is this a suitable question for site? If not why do not change the FAQ? (May be this question is duplicated, but in my opinion this is not suitable question at all).

In SO there is a rule for this: Stack Overflow is not a Link Farm or Search Engine. I think similar rule would be helpful, without adding anything to close options.


P.S: Also seems OP is too new in CS, e.g he thinks making heap takes O(n log n), or he never looked in well studied books to find anything about median.

$\endgroup$
  • $\begingroup$ I would certainly be interested in how you create a heap in o(n log n) given arbitrary lists. $\endgroup$ – Raphael May 26 '12 at 12:49
  • $\begingroup$ @Raphael, Creation of heap is O(n), and you can find it in all algorithmic text book, like clrs, I said OP is new and don't know this task is not O(n log n), as you heapsort is O(n log n), not because of heap creation, because of log n times which will be spent for each item removing. (e.g see heapify function on wiki), also take care o and O are different things. $\endgroup$ – user742 May 26 '12 at 13:09
  • $\begingroup$ Ah, I only remembered the rough analysis. $\endgroup$ – Raphael May 26 '12 at 14:33
6
$\begingroup$

There has been some discussion of introducing a new close reason, “general reference”:

This question is too basic; it can be definitively and permanently answered by a single link to a standard internet reference source designed specifically to find that type of information.

This close reason is currently available on two Stack Exchange sites: English Language and Usage and Science Fiction and Fantasy. The return from experience is mixed: it's useful sometimes, but has a huge potential for abuse.

I've written my opinion on general reference as a close reason on the main meta; here's a quick summary. I disagree with Google as a benchmark for declaring a question unworthy of the site, because it is harder to find relevant search results when you have no idea of what the answer is, and most importantly it is very hard to evaluate whether the search results are reliable and give a complete picture.

A far better metric (and this is the way we apply closing as general reference on SF&F, and the way we use “too localized” in the absence of “general reference” on French Language and Usage) is to look up the obvious keyword in the obvious reference. Wikipedia is the obvious reference in many cases (on French SE, “any dictionary would give the answer” is the usual metric).

So let me look up median. It's all about statistics, the article doesn't have the word “array” anywhere. Ok, maybe it's in another article listed on the disambiguation page. Hmmm, no.

Now let me try your Google search. The top results for me are:

So I disagree that this question is too easy for this site. It doesn't show a lot of effort — I do agree that the asker should have at least been able to find the Wikipedia page on selection algorithms — but it is a legitimate question.

I strongly object to your remark that “OP is too new in CS”. There is nothing wrong about being new to CS, this site is about computer science at all levels. Please read

$\endgroup$
  • 1
    $\begingroup$ I agree with your general position, but not on this particular question. The first search result you list completely relevant. Also, searching for median linear time yields correct results. Furthermore, the Wikipedia article has its own section on efficient computation. So yea, this one is easy to answer (or at least to focus) by searching. $\endgroup$ – Raphael May 19 '12 at 10:20
  • 2
    $\begingroup$ @Raphael How can the first result be relevant, when it does not contain the answer? Furthermore, even if it did, someone had to ask the question on Stack Exchange first! Ok, the Median article does have a link to the answer — not that obvious and with a “citation needed” note. Don't vary search terms too much: what is obvious to you is not obvious to someone who is new to the topic. $\endgroup$ – Gilles May 19 '12 at 10:23
  • $\begingroup$ My search query is main part of question title:"median of an unsorted array", and IMHO all first three answers are relevant. Also this site differs to SO, as you know in SO, too many times we will write, what have you tried (like my comment in this question, and it's one of a reason to close, actually community members defined this not community rules), and we close the question. Also I'm sure you saw SO answers are not links (on SO), and answer to this question could result to link, I don't think we can answer better than wiki, or clrs. $\endgroup$ – user742 May 19 '12 at 10:25
  • 1
    $\begingroup$ @Gilles: I think adding "linear time" is fair, given that the OP asks for O(n) algorithms. The median is (roughly) the n/2-th largest element, so the SO question and its accepted answer is (obviously?) applicable (and leads to the correct WP article). I assume here the OP knows what the median is (which is easy to find out from its article). $\endgroup$ – Raphael May 19 '12 at 10:27
  • 1
    $\begingroup$ Also I mentioned OP is new, but my intention was to say "being new in CS doesn't mean you can't work with search engines", Also I offered to edit our FAQ, in fact we can update our FAQ to say what are expected valid question, I didn't say to add another close option. $\endgroup$ – user742 May 19 '12 at 10:27
  • 1
    $\begingroup$ @SaeedAmiri I used the same search query as you, and I showed you the 5 top results (for me, Google returns different search results to different people). Only the Wikipedia article is relevant, and it has a non-obvious title and is not straightforward to apply to this particular question. $\endgroup$ – Gilles May 19 '12 at 10:27
  • $\begingroup$ @Gilles, at least first three result of both of our searches are same, I don't know which one is irrelevant? $\endgroup$ – user742 May 19 '12 at 10:30
  • $\begingroup$ @Gilles: Google's filter bubble does not help the discussion, that's why I included a search on an engine that does not have this kind of bubble. $\endgroup$ – Raphael May 20 '12 at 10:47
  • 1
    $\begingroup$ I'd like to have "general reference" as a close reason here. We would have to discuss what this means for us, obviously. In particular, CS students who do not look into common text books (Sipser, Cormen et al., ...) might be considered too lazy to be helped, but laymen might not have easy access to those books. Wikipedia is certainly a base line. $\endgroup$ – Raphael May 20 '12 at 10:49
  • $\begingroup$ @Raphael, I think it should be fine to ask questions without looking at the textbooks like Sipser, CLRS, etc. Mathematics accepts similar questions (and even trivial questions) and they don't seem to cause a problem, in fact one can argue that that is part of the reason why Mathematics works so well. The point that one might not like a question doesn't mean it is an invalid question, if you don't like a question don't update/answer it, not all questions are going to be compatible with our taste for good questions. Even if the OP is capable of finding an answer in a textbook that would not make it $\endgroup$ – Kaveh May 22 '12 at 17:14
  • $\begingroup$ an invalid question for the site. Part of the goal here is to help others with question in topics we are more knowledgeable about. The might find the answer in CLRS if they go through it but what is the point of it if someone knowledgeable about the topic can answer it off-the-head? As long as OP has shown some effort to find the answer by themselves they are not too lazy. $\endgroup$ – Kaveh May 22 '12 at 17:16
1
$\begingroup$

I think Gilles is right: we need some policy for "general reference" questions. There is no sense in duplicating easily found and accessible content, e.g. on Wikipedia.

On the particular case, I disagree. The answer to the question is (relatively) easily found via web searches, for instance "median linear time" (DuckDuckGo, Wikipedia). This means two things:

  1. The answers are likely to copy easily obtainable material.
  2. The OP has not put in effort himself.

Therefore, there is no harm done in closing the question.

Note that the situation would be different if the OP said: "I found this and that, but I don't get it: why does X hold?" We would have a different, better question then.

$\endgroup$
  • $\begingroup$ This answer is intended to provide a "voting" alternative to Gilles'. $\endgroup$ – Raphael May 20 '12 at 22:49
  • 1
    $\begingroup$ “I think Gilles is right” and yet I'm downvoting. I disagree with a policy that involves a search engine to determine questions that are too easy. $\endgroup$ – Gilles May 21 '12 at 0:30
  • $\begingroup$ Even when there is an answer on these sources an answer from an expert may reveal information, knowledge, and insight these articles lack. Here is a good example. The question looks quite easy but I don't know if there is any place you can find this in. A better criteria, in my opinion, is whether the OP has put some effort trying to answer the question by themselves before asking other to help. $\endgroup$ – Kaveh May 21 '12 at 4:52
  • $\begingroup$ If the OP has tried to answer the question by themselves first (by using Google, Wikipedia, Searching for similar questions on the SE network, etc.) and hasn't been able to find a satisfying answer or doesn't understand the answers (it happens, you cannot expect much from a first year undergraduate) then the question is fine. IMO, the difficulty is not what is relevant, what is relevant is that OP has spent time thinking about the question and has shown effort in answering the question before asking others for help. $\endgroup$ – Kaveh May 21 '12 at 4:52
  • 1
    $\begingroup$ I agree, Kaveh. However, if the OP does not say what he has tried and does not list failed approaches, we can not know what he has done. If -- as in this case -- the solution is easy to find, this means he has not tried at all (imho). Therefore, close. You can understand "easy to find via Google" or "in Wikipedia" also as benchmark for "has he tried the obvious ways?" which, if answered negatively, means he has not tried at all. $\endgroup$ – Raphael May 21 '12 at 7:59
  • $\begingroup$ Raphael, We don't have anything in close options or FAQ, to close questions without effort, my point is, this question is effortless, so it's better to close it, but this is just my opinion, it's not CS rule, may be we need add some information to FAQ part, to say what are the valid questions in this site. $\endgroup$ – user742 May 21 '12 at 10:47
  • $\begingroup$ @Kaveh Just noticed: "Even when there is an answer on these sources an answer from an expert may reveal information, knowledge, and insight these articles lack. Here is a good example. The question looks quite easy but I don't know if there is any place you can find this in." -- we have argued before whether bad questions with good answers should be closed, and said "yes", provided the question can not be salvaged. I think that is a reasonable strategy. There can be gems of wisdom in answers to any question; that does not mean we should allow every crappy question. $\endgroup$ – Raphael May 21 '12 at 11:13
  • $\begingroup$ @Raphael, regarding the first comment: I agree. regarding the second comment: I guess you are referring to the discussion on cstheory meta. Remember that they are not bad questions but only off-topic because of cstheory's scope. I don't think that applies to Computer Science so level of difficulty should not be a concern. $\endgroup$ – Kaveh May 21 '12 at 13:58
  • $\begingroup$ @Kaveh: No, that discussion was on and about cs.SE. In the early days, though, so I don't quite remember the question that prompted it. I think it was programming language related. $\endgroup$ – Raphael May 21 '12 at 15:09
  • $\begingroup$ @Raphael, then it seems I have forgotten it. :) $\endgroup$ – Kaveh May 22 '12 at 1:38

You must log in to answer this question.