# Are computer science questions allowed?

Mathematics and computer science go hand in hand, and often when I write code I stop and review and ask myself "Is there a better way of doing what I just did?"

This is a highly mathematical question. Is $X$ faster than $Y$. Are questions like that allowed? Or questions like posting / explaining your code and asking what is the runtime order?

• Are you aware of cs.stackexchange.com? – Aryabhata Jul 7 '14 at 16:31
• I am now. Guess that answers my question :) – Oria Gruber Jul 7 '14 at 16:33
• It might be on-topic here if by "faster" you mean algorithmic complexity/efficiency is the basis for answering. In such cases the Question would likely be on-topic for CSTheory as well. For numerical analysis Questions the scientific computation SE (confusingly branded Computational Science) might the best choice. – hardmath Jul 7 '14 at 16:52
• PSA: one can use site shortcut links in comments: [cs.se] becomes Computer Science, [cstheory.se] becomes Theoretical Computer Science and so on... – user147263 Jul 7 '14 at 17:33
• @hardmath: cstheory is for research level questions (like mathoverflow). – Aryabhata Jul 7 '14 at 18:05
• math.stackexchange.com/tags/computer-science/info – IAmNoOne Jul 7 '14 at 18:13
• Just running your question through my Turing machine. Will get back to you when the tape stops. – Level River St Jul 17 '14 at 14:30

Short answer: Yes, CS questions are allowed, but only if they are mathematical in their focus.

Long answer: We are a math website. Thus, the questions you ask must be mathematical in nature. (Big surprise.) If your CS question is primarily mathematical, we will accept it here. If your CS question is asking about implementation, some feature of a specific language, etc., it will not be welcomed very nicely.

A good rule of thumb could be "Do I need to know how to program in language X in order to read or to answer this question?" If yes, then it's off topic. If no, then it's probably fine.

We don't like reading long listings of code; rather, please convert to pseudo-code before posting. We also shouldn't need to know anything about computer architecture to answer your question (e.g. "is this algorithm faster, because it's accessing the L2 cache, vs this one that's working in memory?" is not good).

Some history of this discussion:

• If you need to know how to program in language X to read and/or answer the question, the question is probably off-topic on Computer Science, too, and should be posted to Stack Overflow instead. – David Richerby Jul 8 '14 at 9:04
• If you need to know how to program in language X then it isn't a computer science question to begin with. "Computer science is no more about computers than astronomy is about telescopes." (attribution disputed) – DanielV Jul 10 '14 at 16:42
• Their could be occasion to include code into an answer, given a certain type of question. For instance I think that it would be appropriate to include Lisp code to a question like this(if I were to expand my comment into a answer) :math.stackexchange.com/questions/851881/… to illustrate the point about different syntaxes having different order of operations. – Baby Dragon Jul 13 '14 at 22:55