53

Should the titles of questions be phrased as questions?

For example, if I would like to learn good ways to "foo" a "bar", which is a better question title:

  • How do I foo a bar?
  • Fooing a bar

Let's assume that in both cases I explicitly spell out the question in the body.

Which version is preferable and why?

1

12 Answers 12

61

"How do I foo a bar?"

Advantages:

  1. They're explicitly called questions so non-question phrasing is grammatically jarring.
  2. Overall consistency of style across the site.
  3. Someone finding the question via a Google search may have a better sense of what they're clicking on if the title is phrased as a question. I.e., they're reaching a question-and-answer site as opposed to a tutorial or essay on the given topic.
  4. Although it's possible to clearly convey the point of the question with either format, enforcing the question phrasing is more likely to yield a self-explanatory title. Otherwise people might start using titles like "Styles for Question Titles", which is insufficiently specific. In other words, it helps avoid a slippery slope.

Exceptions may occasionally exist, but the default should be to put an explicit question in the title.

0
45

A good question is going to give the reader as much context in as short a space as possible. A good question is going to let the reader know what he is going to read, and in this case, let the answerers know what end-state you desire.

Let's take your first example, "Fooing a bar". Although short, it lacks context. There's nothing in the question that indicates what sort of answer that could be. Possible actual questions include:

  • Philosophy: Is it wise to foo a bar?
  • Advice: When should I foo a bar but baz a bar?
  • Mechanics: How do I foo a bar?
  • Possibility: Can I foo a bar?
  • Comparison: How many different ways can I foo a bar?
  • Survey: How do you foo a bar?

Those extra words aren't just sitting there doing nothing. Each one of those is a different question with a different answer and a potentially different audience. They are directing the answer and informing the reader. Choosing the right question is the key to getting the answer that you need.


@dreeves:

You coudln't leave well-enough alone, so it's full disclosure time. You've neglected to tell everyone that you are asking this because you and I are going back and forth on four of your questions, all of which you made community wikis but do not accept edits:

You don't really care what Stack Overflow does. You're building your case, without showing people the context, of something you are trying enforce. Indeed, you spoil the debate by "seeding" it with both sides before the community even had a chance to respond. You've intentionally biased the community to favor you. You're not interested in what the community should do, you're just pushing the community toward what you want. It's all very unethical and slimey.

  1. None of my edited titles are excessively longer than original. If you are going for short, you don't achieve that since you could make your titles shorter without loss of information (although still missing needed context). "Short" is specious. You don't really want that, as evidenced by the long and convoluted titles of your other questions. You're using it as a justification to rationalize not accepting edits.

  2. I don't know why you have trouble "visually grepping". That seems to be something you need to work out on your own. You're arguing about what you find easy, although what most people find easy are full questions because they are used to this from FAQs and customer service documents. You're thinking about yourself instead of the community, and the Google-indexing of the content here. You don't seem to optimize your other question titles for whatever "visually grepping" means.

  3. You argued about your "mini-essay" idea in your second email to me, as you forget the counterpoint that I responded with (again, because you aren't being fair in this argument). You don't intend these to be mini essays. You're asking poll-style questions about beginner-level topics already covered in the Perl docs. Neither your "extended" explanation or any of the answers have been mini-essays. Although your intent may have been for them to be that, they haven't been. You mention in this question that one title form should be okay if you fully explain the question later, but you didn't do that previously. You've edited at least one question very recently to do that, but that hasn't been your style up to now. You're being dishonest here.

  4. None of my edits have been convoluted. Your versions, however, have been, including the title to this question. Two people agreed that you need a better title for this question and one of them has a better title, but you dismiss them. Clearly, you just don't want people editing what you've done. Your other question titles are a mess. You don't really have the goal of making things short or explaining further in the extended question. You have the goal of making things the way you did first. That is, you choose the "community wiki" flag, but don't really want it to be a wiki or belong to the community. Your real goal is ownership, and that's what you told me in email. However, you don't address that in your arguments, do you?

  5. If you're sure about something, why are you posing a question? This gets back to your mini-essay idea, but you don't follow through on it. You don't provide the mini-essay. Your answers to your own questions don't explore the subject in any depth, and your answers often show that you don't know the depth of the subject. So, if you aren't asking a question, why are you wasting people's time trying to get answers? That time could go to someone else who really has a question.

7
  • 1
    +1 for specificity in the question. I'd like to add "- Why is foo barring?"
    – Svante
    Dec 18, 2008 at 19:19
  • 2
    I've got some code I need help with, if you guys want to stop wasting time on SO maybe I could email it to you?
    – yar
    Dec 29, 2008 at 21:40
  • Is it just me or is 23673 not what the author intended?
    – Gnome
    Mar 23, 2010 at 11:24
  • 1
    @Gnome: No, you're right, it should be 236737. The revision history is gone now, but there was a long and drawn-out edit war. Also, that was back when 5k users could delete anyone's comments, which made it rather worse.
    – mmyers
    Mar 23, 2010 at 15:16
  • @mmyers - "Also, that was back when 5k users could delete anyone's comments" - Ah, the halcyon days of stackoverflow's youth! /me pines for days of yore...
    – Pollyanna
    Mar 23, 2010 at 15:48
  • 3
    @Pollyanna: /me wood pine fir yew, but that wood be odd.
    – mmyers
    Mar 23, 2010 at 15:57
  • 1
    Editing posts for technical clarity is helpful, asserting your personal opinion on form is not only unhelpful it is impolitic. What if someone feels the need to do the same to your questions on no basis other than personal opinion on form? You wouldn't like that would you? If you are more interested in being the question Nazi, forcing everyone to write questions according to your rigid doctrines, than actually answering questions I think you've missed the point of these sites. These sites are about collaboration so there will be many styles and none are "right," get used to it.
    – Mike Bethany
    Dec 10, 2010 at 16:53
25

It depends.

Some questions lend themselves to the terse "Fooing a bar." format. Others are more clear as "How do I foo a bar?"

Priorities:

  1. Be clear.
  2. Be terse.

As an example of "Fooing a bar" which I think would not be improved by phrasing it as a question, "static ChannelFactory in Global.asax.cs throws CommunicationObjectFaultedException". It's a very specific topic with a necessarily long title which would have no advantage if phrased as a question.

9
  • 1
    I would argue that the former is less clear - "fooing a bar" could just as easily reference a tutorial or article, which is most definitely not a question. Nov 25, 2008 at 20:10
  • 3
    However, within the context of SO, we "know" that we're dealing with questions in some sense.
    – Larsenal
    Nov 25, 2008 at 20:15
  • 1
    The argument I'm making is about clarity. Clarity includes not relying on assumptions to make your point. Yes, in the context of SO, we know we're dealing with questions, but about about Google search results? This reduces the clarity for those users expecting a tutorial and getting something else. Nov 25, 2008 at 21:47
  • Do I love answers that totally beg the question? It depends.
    – yar
    Dec 29, 2008 at 21:39
  • Can you give examples of each? Mar 23, 2010 at 15:34
  • @TJC: A question for title is easier when you don't understand the problem because you can merely paraphrase the body text, but can often be cleaned up (possibly by someone else). If cleaner/clearer version is shorter without losing meaning, I prefer it.
    – Gnome
    Mar 23, 2010 at 17:04
  • I don't have canned examples, but going through my edit history: stackoverflow.com/posts/272428/revisions, stackoverflow.com/posts/1744144/revisions, stackoverflow.com/posts/2490208/revisions, stackoverflow.com/posts/236737/revisions, and (slightly longer, but better, and fits the FAQ style) meta.stackoverflow.com/posts/5999/revisions. The second shows a title improvement by adding a term the OP wasn't familiar with, and the same goes for tags.
    – Gnome
    Mar 23, 2010 at 17:10
  • +1 for laying down the law: clear and terse. That's the key.
    – MPelletier
    Mar 23, 2010 at 21:11
  • 2
    Some topics require titles that are very long due to the specific phrases needed to identify the topic. If in addition the topic is clearly a "how do i fix this problem?", adding something like "How do I fix..." is no better, IMO, than succinctly describing the problem.
    – Larsenal
    Jul 21, 2010 at 20:14
20

"Fooing a bar."

Advantages:

  1. Shorter. Fewer superfluous words means more room for keywords.
  2. Easier to visually grep through and sort questions by title if they don't all start with "How do I".
  3. The title of a question is just that, a title. The question itself can legitimately be in the body.
  4. It's what you might choose for the title of a collection of mini-essays on a (perhaps highly esoteric) topic, which is consistent with Joel and Jeff's originally articulated vision for Stack Overflow.
  5. Some questions (cf. this one [added: though the commenter below managed it nicely]) would just be too convoluted to try to phrase as questions. In any case, full consistency of style in this regard is not really an option anyway.
  6. Lets you reserve literal questions for things you're actually uncertain about, such as "Is the C-preprocessor Turing-complete?".
  7. The creators of Stack Overflow, at least sometimes, do it this way. For example, Parameterize an SQL IN clause and Diagnosing Deadlocks in SQL Server 2005.

As long as the title clearly conveys what the question is about, it need not be explicitly in the form of a question.

0
6

It totally depends. But the title must either be clear about the question, or be an invitation to read further.

I have seen some very bad titles (like "I Need Help!!!!", with several exclamation marks). But that is completely useless.

In my opinion, if you want somone else to take care to answer the question, you should take care to ask it.

0
6

I am pretty sure that nowhere in the FAQ does it say the TITLE of the question has to be in the form of a question. Edits that change it to be like that irritate me.

2
  • 2
    Agreed. Nor does it say anything about spelling, grammar, punctuation, or even English (as opposed to French/German/etc). Although, readability/comprehensibility are implicitly necessary for an answer to your question.
    – rlb.usa
    Mar 23, 2010 at 22:38
  • Currently, it is now in the meta FAQ post, How do I write a good title? — "Use proper grammar and write in question form." Apr 27, 2023 at 11:01
6

If it is posted on SO is it not a question? If you post a statement aren't you saying implicitly that you need help with [insert subject here]? Isn't it assumed that the person is asking a question they need help with?

So is it the clarity of the question or its form that are more important? Would you agree that it is the clarity of the question and not the form? Wouldn't you rather have a clearly stated statement that isn't in the form of a question than a poorly structured question? If the statement is clear isn't it nitpicking to change it into a question? Aren't you simply demanding that others go by your preferred style? Are you helping any by doing this?

And what if it isn't actually a question like the incorretly titled "Nokogiri oddness?" He's not asking if there is Nokogiri oddness is he? Isn't he actually making the statement "Here is some Nokogiri oddenss I've observed."? Doesn't it actually make it less clear to place a question mark at the end of a statement of fact? Wouldn't you think, "Are you asking or saying?"

Shouldn't we allow each writer to express some personal style and creativity? Isn't it more important to focus on the actual problem than forcing personal opinions about style on others? Doesn't that miss the entire point of these sites? Doesn't it in fact detract from helping and turn it into petty bickering over opinion?

So, does it make sense to force everything into the form of a question?

1
  • 2
    Can you believe it took me till paragraph 3 or so to, as they say, see what you did there?
    – dreeves
    Dec 11, 2010 at 2:27
3

Whatever Google will find. Whatever the built-in search will find. If it can either one, then it doesn't matter.

0
2

The idea that the best possible title for a question will also be a question is, in short, completely off-the-mark. Titles are titles and have their own grammar.

Also, while you can no longer earn many points writing questions on Stack Overflow (new point system + tendency to not upvote questions), the best answers come to questions that have interesting titles/many upvotes/pageviews. Good titles entice the best answerers to read the question.

1
  • 3
    These aren't (supposed to be) essays - pithy titles that draw in readers aren't helpful if they don't communicate the essence of the question itself. It's one thing to suggest abbreviating the title in order to better communicate the question, but quite another to suggest that questions be abandoned entirely because they aren't interesting enough...
    – Shog9
    Mar 23, 2010 at 22:22
0

The rephrasing of titles also plays merry hell with the RSS feed. I find it particularly irritating when the OP had written a clear title phrased as a question, yet the sub-editor still feels compelled to tweak it, frequently adding nothing of real value.

1
  • 3
    That's a problem for the RSS feed. Jeff has declined a "minor edit" field that could prevent that. Feb 24, 2010 at 22:47
-1

The title just needs to be a short summary of the problem. I see no problem with titles like "I have a problem with multiple virtual inheritance". In addition, a lot of my questions just omit the WH words and question mark, since it's obvious it's a question. For example "Non-reentrant C# timer" instead of "how to write a non-reentrant C# timer?".

4
  • 13
    I have a problem with any title that begins "I have a problem"... They strongly indicate that the asker actually has two problems.
    – Shog9
    Jan 9, 2011 at 22:07
  • @Shog9 I agree it's not a very pretty title, but could you elaborate why it implies two problems?
    – Oak
    Jan 9, 2011 at 22:14
  • 8
    to me, such a title indicates that the user not only doesn't understand the topic they're asking about, but also (at least while writing the title) failed to think it through far enough to identify what they're stuck on. Do they not understand how multiple virtual inheritance might be used? What pitfalls exist when using it? Whether or not it's compatible with another pattern? The title tells us nothing that a good set of tags wouldn't. Titles like "C# Question" epitomize this sort of [lack of] thinking.
    – Shog9
    Jan 9, 2011 at 22:18
  • 4
    Too often I see titles like "Non-reentrant C# timer" for both questions about a problem with an existing thing and questions that ask for some starting point to start writing such thing. Both "I have a problem with multiple virtual inheritance" and "Non-reentrant C# timer" are bad summaries, in my opinion.
    – Arjan
    Jan 10, 2011 at 11:33
-3

No. This isn't Jeopardy.

This is a technical forum and it should be dedicated to content - as long as there is meaning in the question users should not be bothered with petty details like this, which give no additional value to the forum such as. They have other things on their minds (like, solving a problem or looking for a solution).

However, if someone wants to go and edit question titles to fit the form of a question, I have no complains. Just don't ask it of everyone.

3
  • 1
    As an aside: the FAQs do mention Jeopardy. I think that reference in the FAQs only applies to self-answered questions, and merely implies one should not answer within the question itself. Still, that reference might be confusing -- see meta.stackexchange.com/questions/39012/… (Detail: this is not a forum as we know it though.)
    – Arjan
    Mar 30, 2010 at 10:39
  • @Arjan - "forum" <-- of course, but in lack of a better term... I don't know what to call these sites, anyways.
    – Rook
    Mar 30, 2010 at 22:31
  • In any case, the emphasis in my answer was on the "no additional value".
    – Rook
    Mar 30, 2010 at 22:32

You must log in to answer this question.

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