28 votes
Accepted

Code that handles n% of test cases but not all

If the code produces wrong answers for some test cases, then the author is aware that the code is not working correctly as intended, and the question is thus prima facie off-topic for Code Review. ...
24 votes
Accepted

Can I edit broken code if I'm sure I'm recreating OP's original code?

I prefer to err on the side of commenting and closing, rather than fixing the code for them. Reasons include: Fixing broken code is a slippery slope. Newer users will see that and assume that ...
21 votes
Accepted

PSA: Excel going "Not Responding" isn't broken code

If you don't do VBA, you probably don't know this, but most VBA host applications are single-threaded, and when VBA code runs for a long time it's completely normal that the main window's caption says ...
18 votes
Accepted

How broken does code have to be to for a question to be closed?

OP doesn't seem to know their code is broken. Perhaps due to insufficient testing, but to the best of their knowledge, the code works and produces the expected output. The "spirit" of the "working ...
15 votes

Why was my edit to fix an answer rejected, even though it was approved by the author?

When you do a suggested edit, the only information besides the edit that is shown to reviewers is the edit reason. Yours was Fixed the answer in regards to the question. This does not indicate ...
  • 21.4k
14 votes

Are questions with undiscovered bugs allowed?

For this particular case, it's a common beginner error, that wouldn't show up during runtime unless the out-of-bounds reads lead to a win because it happened to look like 4 in a row. I've had plenty ...
  • 4,332
14 votes
Accepted

Asking a question to understand why code is broken gets closed

I will refer first to Stack Overflow's on-topic page, as your question (in its original form) would actually be a better fit there (emphasis mine): What topics can I ask about here? Stack Overflow is ...
  • 20.3k
14 votes

Why was this question closed as off-topic after a bug was discovered by the answers?

I'm one of the users who voted to close. I saw that at least two bugs were discovered, and that made me think the code is severely buggy and therefore troublesome to review. But I saw it wrong. After ...
  • 110k
13 votes

How broken does code have to be to for a question to be closed?

The rule states that the code must work correctly, to the best of the author's knowledge. Usually, if the author does not mention any known bugs, then it's an allowable question. That said, if the ...
13 votes
Accepted

I think my code might have a bug, but I am not sure if it actually does, is it broken code?

If that message isn't the intended behavior, and you're looking for a solution to that specific issue, the right thing to do is to post a MCVE that reproduces the problem on Stack Overflow. If that ...
13 votes

Are questions with undiscovered bugs allowed?

If you ask yourself: Can you play a game of connect four with their code? And your answer is: Yes, except in some special case - which someone may be unlikely to test. Then no the question ...
  • 42.2k
12 votes

Why was my edit to fix an answer rejected, even though it was approved by the author?

First of all, your edit is totally legit (thank you!), and it should have been approved. The edit was rejected because 2 of 2 reviewers voted so, and by the powers that be (the Stack Exchange ...
  • 110k
11 votes
Accepted

Reviewing non-working code when author thinks it's working?

If we take a look at https://codereview.stackexchange.com/help/on-topic we see To the best of my knowledge, does the code work as intended? if the OP answered this for him/her-self with yes, then the ...
  • 50.1k
9 votes

Reviewing non-working code when author thinks it's working?

Unfortunately, your question is based on a faulty premise. The code to be reviewed consists of a makeBst() function with one test case. That test case produces ...
9 votes

Are questions with undiscovered bugs allowed?

I just voted to Reopen. My reasoning: As far as the poster knew at the time of posting, the code worked. The code works for most situations. Two people answered, so the poster can't fix the code ...
  • 21.4k
8 votes

Are questions with undiscovered bugs allowed?

It is unreasonable to insist that code posted for review has no bugs. It is reasonable to require that code posted for review has no known bugs. The rule exists so that we can concentrate on ...
  • 67.7k
8 votes

Review one-by-one feature?

The short answer is, if you know that your code has deficiencies that need to be fixed, then it is not ready to be reviewed here. In general, we expect questions to have no known bugs. It might be ...
8 votes

Is code "working as intended" if significant portions are hardcoded?

That question sure looks like a "gimme teh codez" disguised as a request for a code review. I guess it's fair to ask "what qualifies as 'working' and who are you to judge my code if it ...
  • 156
7 votes
Accepted

Posting a question where part of the code contains a known bug

If I read your question and the help center correctly, the code has to work as intended. If the bug prevents that, it's out. If the bug is considered acceptable, there is no problem. Should the bug ...
  • 13k
7 votes

"Count maximum number of thieves that can be caught" question should be reopened

The question says: Out of 24 test-cases 18 passed, the rest got the wrong answer. If the approach is wrong I would like to know the correct answer. As per the Help Center rules, broken code is ...
7 votes

"How get all id from the db insert" question closed as "not ready for review"

There are several problems with your question: There is no language tag. Is it php? It lacks context. What does the code for db.images.Add(…) and ...
7 votes

Is our "broken" wording broken?

Yes. There seems to be some confusion about what we mean by broken. For some of us, it's natural that it means code that does not work as intended, but it seems like other users of the site are ...
  • 42.2k
7 votes
Accepted

Is the Code Review SE the right site for checking if the code of my Arduino project minimizes the risk of overheating as much as possible?

To my eyes your question could only be off-topic for one rule. To the best of my knowledge, does the code work as intended? -- help center And from your description your code seems to work as ...
  • 42.2k
6 votes

Is our "broken" wording broken?

It's not broken. It just doesn't produce the right answer. That is broken. Code which compiles or code which is accepted by an interpreter is not necessarily doing what it should be doing. If "broken"...
  • 13k
6 votes
Accepted

What to do with question with compiler warnings/errors due to copy & paste error

You only realized after the fact and after receiving answers that the code you had posted was broken, and it wasn't clearly-enough broken to be pointed out and closed as broken code at a glance. I'd ...
6 votes

Why was this question closed as off-topic after a bug was discovered by the answers?

Since I wasn't involved in this question at all, I'll just try to make sense of the situation based on the norms of this site. The first answerer, @Dair, wasn't originally aware that the code was ...
  • 34.8k
5 votes

Can I edit broken code if I'm sure I'm recreating OP's original code?

IMO the code of a question should never ever be edited. The only exception to this rule is if it is a clear copy&pasta error. If the OP knows the language well enough I assume he/she could edit ...
  • 50.1k
5 votes
Accepted

Made a code-review of broken code, but flagged it as well

From the description of the question, I think it was quite clear that the code doesn't work as intended. As such, the code was not ready for review here, and the question was likely to get closed. In ...
  • 110k
5 votes

Is undefined behavior (for C/C++ code) off-topic here?

You are kind of missing the point that this whole site Code Review is about code reviews, which is a well-known term for peer review by other programmers. It is not about discussing language features ...
  • 4,455
4 votes

"How get all id from the db insert" question closed as "not ready for review"

public DataTable dtImages = new DataTable(); // EF Context for the DB public CameraCollectorEntities db = new CameraCollectorEntities(); These are public fields, ...

Only top scored, non community-wiki answers of a minimum length are eligible