luni, 22 octombrie 2012

Don't know the answer? Here's what to say ...

We've all been there. It's Friday afternoon and work is winding down. You're sitting in your cube, watching a YouTube video of a bunny kissing a squirrel and jamming to your "Friday Fun" iTunes playlist. Just as you're about to press "share" on that cute/creepy bunny video, your boss stops by and asks you for a quick recap of your client's latest earnings report. You're completely caught off guard, and all you manage to mumble is, "Um, uh, I'm actually not sure about that ... um, sorry."


After your boss walks away, your face turns from fire-engine red back to its normal hue and your brain starts functioning again, you kick yourself because you do know the answer. Well, sort of. The other day you'd read a summary from the earnings call and you remember some of the details, or at least enough to have pieced together a more coherent response.


Unless you're one of those lucky (some might say annoying) people who always has the right answer or has mastered the art of sounding like you know what you're talking about even if you don't have a clue, then you have been or will be faced with similar situations where you aren't fully prepared. But chances are, even if you don't have the full answer, you do know enough to share some information and then follow up once you know more. This way, you show your boss that you do have something of value to contribute, while still being honest about not knowing everything.


According to Jodi Glickman, author of "Great on the Job: What to Say, How to Say It. The Secrets of Getting Ahead," answering a question you don't know with intelligence boils down to a simple three-part strategy:


1. Here's what I know.


The first thing to remember is that you aren't expected to know everything about every topic at all times. Given how busy we are these days, it's nearly impossible to always have an answer on the tip of your tongue. According to Glickman, if the question is related to something you're working on or should be familiar with, you likely do know something -- and that something is worth contributing. So instead of just going straight to, "I don't know, sorry," take a second to collect your thoughts and provide your boss with the fact or tidbit you do know.


2. Here's what I don't know.


"After you've given your client or boss a little something to work with, then be transparent and admit that you don't know the answer or have that exact piece of information," writes Glickman. I know sometimes it's easy, when caught off guard, to make something up, but it'll only hurt you in the long run. Your boss would much rather you be honest and plead ignorance than find out later your client didn't actually acquire a new company as you'd told him in your attempt to sound smart. Lying will just ruin your credibility. Instead of dancing around it, simply tell her you aren't completely sure.


3. Here's how I'll figure it out.


While you aren't expected to know everything, you are expected to do what you can to figure out the answer, even if it requires taking some time to research and pull the right information. Step three of Glickman's strategy suggests closing the conversation by proactively offering your game plan -- you'll do some digging and get back to her. It might help to ask for her deadline or if there's anything else she'd like to know while you're looking -- that way you ensure that when you do get your boss the answer, you get it to them on time and with no missing pieces.


Notes Glickman, this method works well because it allows you to bury the negative (that you don't know what you're talking about) in between two positives. "The idea of 'sandwiching' the bad news between the good news ensures that you start off and end on a solid footing."


Here's an example of how you can apply this strategy to the above situation:


1. Here's what I know. "I do know sales for X client are up from last quarter."


2. Here's what I don't know. "However, I don't know the exact sales numbers for this quarter off the top of my head."


3. Here's how I'll figure it out. "So let me go back to the earnings release, double check the numbers, and get back to you. When do you need this information by?"


So the next time your boss stops by unannounced, take a deep breath, remain calm and use this three-part strategy to confidently (kind of) answer the question you (sort of but not really) know the answer to.

miercuri, 17 octombrie 2012

How To Ask Questions The Smart Way

Before You Ask


Before asking a technical question by e-mail, or in a newsgroup, or on a website chat board, do the following:




  1. Try to find an answer by searching the archives of the forum you plan to post to.




  2. Try to find an answer by searching the Web.




  3. Try to find an answer by reading the manual.




  4. Try to find an answer by reading a FAQ.




  5. Try to find an answer by inspection or experimentation.




  6. Try to find an answer by asking a skilled friend.




  7. If you're a programmer, try to find an answer by reading the source code.




When you ask your question, display the fact that you have done these things first; this will help establish that you're not being a lazy sponge and wasting people's time. Better yet, display what you have learned from doing these things. We like answering questions for people who have demonstrated they can learn from the answers.


Use tactics like doing a Google search on the text of whatever error message you get (searching Google groups as well as Web pages). This might well take you straight to fix documentation or a mailing list thread answering your question. Even if it doesn't, saying I googled on the following phrase but didn't get anything that looked promising is a good thing to do in e-mail or news postings requesting help, if only because it records what searches won't help. It will also help to direct other people with similar problems to your thread by linking the search terms to what will hopefully be your problem and resolution thread.


Take your time. Do not expect to be able to solve a complicated problem with a few seconds of Googling. Read and understand the FAQs, sit back, relax and give the problem some thought before approaching experts. Trust us, they will be able to tell from your questions how much reading and thinking you did, and will be more willing to help if you come prepared. Don't instantly fire your whole arsenal of questions just because your first search turned up no answers (or too many).


Prepare your question. Think it through. Hasty-sounding questions get hasty answers, or none at all. The more you do to demonstrate that having put thought and effort into solving your problem before seeking help, the more likely you are to actually get help.


Beware of asking the wrong question. If you ask one that is based on faulty assumptions, J. Random Hacker is quite likely to reply with a uselessly literal answer while thinking Stupid question..., and hoping the experience of getting what you asked for rather than what you needed will teach you a lesson.


Never assume you are entitled to an answer. You are not; you aren't, after all, paying for the service. You will earn an answer, if you earn it, by asking a substantial, interesting, and thought-provoking question — one that implicitly contributes to the experience of the community rather than merely passively demanding knowledge from others.


On the other hand, making it clear that you are able and willing to help in the process of developing the solution is a very good start. Would someone provide a pointer?, What is my example missing?, and What site should I have checked? are more likely to get answered than Please post the exact procedure I should use. because you're making it clear that you're truly willing to complete the process if someone can just point you in the right direction.






When You Ask









Choose your forum carefully





Be sensitive in choosing where you ask your question. You are likely to be ignored, or written off as a loser, if you:





  • post your question to a forum where it's off topic




  • post a very elementary question to a forum where advanced technical questions are expected, or vice-versa




  • cross-post to too many different newsgroups




  • post a personal e-mail to somebody who is neither an acquaintance of yours nor personally responsible for solving your problem





Hackers blow off questions that are inappropriately targeted in order to try to protect their communications channels from being drowned in irrelevance. You don't want this to happen to you.


The first step, therefore, is to find the right forum. Again, Google and other Web-searching methods are your friend. Use them to find the project webpage most closely associated with the hardware or software giving you difficulties. Usually it will have links to a FAQ (Frequently Asked Questions) list, and to project mailing lists and their archives. These mailing lists are the final places to go for help, if your own efforts (including reading those FAQs you found) do not find you a solution. The project page may also describe a bug-reporting procedure, or have a link to one; if so, follow it.


Shooting off an e-mail to a person or forum which you are not familiar with is risky at best. For example, do not assume that the author of an informative webpage wants to be your free consultant. Do not make optimistic guesses about whether your question will be welcome — if you're unsure, send it elsewhere, or refrain from sending it at all.


When selecting a Web forum, newsgroup or mailing list, don't trust the name by itself too far; look for a FAQ or charter to verify your question is on-topic. Read some of the back traffic before posting so you'll get a feel for how things are done there. In fact, it's a very good idea to do a keyword search for words relating to your problem on the newsgroup or mailing list archives before you post. It may find you an answer, and if not it will help you formulate a better question.


Don't shotgun-blast all the available help channels at once, that's like yelling and irritates people. Step through them softly.


Know what your topic is! One of the classic mistakes is asking questions about the Unix or Windows programming interface in a forum devoted to a language or library or tool portable across both. If you don't understand why this is a blunder, you'd be best off not asking any questions at all until you get it.


In general, questions to a well-selected public forum are more likely to get useful answers than equivalent questions to a private one. There are multiple reasons for this. One is simply the size of the pool of potential respondents. Another is the size of the audience; hackers would rather answer questions that educate many people than questions serving only a few.


Understandably, skilled hackers and authors of popular software are already receiving more than their fair share of mis-targeted messages. By adding to the flood, you could in extreme cases even be the straw that breaks the camel's back — quite a few times, contributors to popular projects have withdrawn their support because collateral damage in the form of useless e-mail traffic to their personal accounts became unbearable.







Web and IRC forums directed towards newbies often give the quickest response





Your local user group, or your Linux distribution, may advertise a Web forum or IRC channel where newbies can get help. (In non-English-speaking countries newbie forums are still more likely to be mailing lists.) These are good first places to ask, especially if you think you may have tripped over a relatively simple or common problem. An advertised IRC channel is an open invitation to ask questions there and often get answers in real time.


In fact, if you got the program that is giving you problems from a Linux distribution (as is common today), it may be better to ask in the distro's forum/list before trying the program's project forum/list. The project's hackers may just say, use our build.


Before posting to any Web forum, check if it has a Search feature. If it does, try a couple of keyword searches for something like your problem; it just might help. If you did a general Web search before (as you should have), search the forum anyway; your Web-wide search engine might not have all of this forum indexed recently.


There is an increasing tendency for projects to do user support over a Web forum or IRC channel, with e-mail reserved more for development traffic. So look for those channels first when seeking project-specific help.







As a second step, use project mailing lists





When a project has a development mailing list, write to the mailing list, not to individual developers, even if you believe you know who can best answer your question. Check the documentation of the project and its homepage for the address of a project mailing list, and use it. There are several good reasons for this policy:





  • Any question good enough to be asked of one developer will also be of value to the whole group. Contrariwise, if you suspect your question is too dumb for a mailing list, it's not an excuse to harass individual developers.




  • Asking questions on the list distributes load among developers. The individual developer (especially if he's the project leader) may be too busy to answer your questions.




  • Most mailing lists are archived and the archives are indexed by search engines. If you ask your question on-list and it is answered, a future querent could find your question and the answer on the Web instead of asking it again.




  • If certain questions are seen to be asked often, developers can use that information to improve the documentation or the software itself to be less confusing. But if those questions are asked in private, nobody has the complete picture of what questions are asked most often.





If a project has both a user and a developer (or hacker) mailing list or Web forum, and you are not hacking on the code, ask in the user list/forum. Do not assume that you will be welcome on the developer list, where they're likely to experience your question as noise disrupting their developer traffic.


However, if you are sure your question is non-trivial, and you get no answer in the user list/forum for several days, try the developer one. You would be well advised to lurk there for a few days before posting to learn the local folkways (actually this is good advice on any private or semi-private list).


If you cannot find a project's mailing list address, but only see the address of the maintainer of the project, go ahead and write to the maintainer. But even in that case, don't assume that the mailing list doesn't exist. Mention in your e-mail that you tried and could not find the appropriate mailing list. Also mention that you don't object to having your message forwarded to other people. (Many people believe that private e-mail should remain private, even if there is nothing secret in it. By allowing your message to be forwarded you give your correspondent a choice about how to handle your e-mail.)







Use meaningful, specific subject headers





On mailing lists, newsgroups or Web forums, the subject header is your golden opportunity to attract qualified experts' attention in around 50 characters or fewer. Don't waste it on babble like Please help me (let alone PLEASE HELP ME!!!!; messages with subjects like that get discarded by reflex). Don't try to impress us with the depth of your anguish; use the space for a super-concise problem description instead.


One good convention for subject headers, used by many tech support organizations, is object - deviation. The object part specifies what thing or group of things is having a problem, and the deviation part describes the deviation from expected behavior.


Stupid:

HELP! Video doesn't work properly on my laptop!


Smart:

X.org 6.8.1 misshapen mouse cursor, Fooware MV1005 vid. chipset


Smarter:

X.org 6.8.1 mouse cursor on Fooware MV1005 vid. chipset - is misshapen



The process of writing an object-deviation description will help you organize your thinking about the problem in more detail. What is affected? Just the mouse cursor or other graphics too? Is this specific to the X.org version of X? To version 6.8.1? Is this specific to Fooware video chipsets? To model MV1005? A hacker who sees the result can immediately understand what it is that you are having a problem with and the problem you are having, at a glance.


More generally, imagine looking at the index of an archive of questions, with just the subject lines showing. Make your subject line reflect your question well enough that the next guy searching the archive with a question similar to yours will be able to follow the thread to an answer rather than posting the question again.


If you ask a question in a reply, be sure to change the subject line to indicate that you're asking a question. A Subject line that looks like Re: test or Re: new bug is less likely to attract useful amounts of attention. Also, pare quotation of previous messages to the minimum consistent with cluing in new readers.


Do not simply hit reply to a list message in order to start an entirely new thread. This will limit your audience. Some mail readers, like mutt, allow the user to sort by thread and then hide messages in a thread by folding the thread. Folks who do that will never see your message.


Changing the subject is not sufficient. Mutt, and probably other mail readers, looks at other information in the e-mail's headers to assign it to a thread, not the subject line. Instead start an entirely new e-mail.


On Web forums the rules of good practice are slightly different, because messages are usually much more tightly bound to specific discussion threads and often invisible outside those threads. Changing the subject when asking a question in reply is not essential. Not all forums even allow separate subject lines on replies, and nearly nobody reads them when they do. However, asking a question in a reply is a dubious practice in itself, because it will only be seen by those who are watching this thread. So, unless you are sure you want to ask only the people currently active in the thread, start a new one.







Make it easy to reply





Finishing your query with Please send your reply to... makes it quite unlikely you will get an answer. If you can't be bothered to take even the few seconds required to set up a correct Reply-To header in your mail agent, we can't be bothered to take even a few seconds to think about your problem. If your mail program doesn't permit this, get a better mail program. If your operating system doesn't support any e-mail programs that permit this, get a better operating system.


In Web forums, asking for a reply by e-mail is outright rude, unless you believe the information may be sensitive (and somebody will, for some unknown reason, let you but not the whole forum know it). If you want an e-mail copy when somebody replies in the thread, request that the Web forum send it; this feature is supported almost everywhere under options like watch this thread, send e-mail on answers, etc.







Write in clear, grammatical, correctly-spelled language





We've found by experience that people who are careless and sloppy writers are usually also careless and sloppy at thinking and coding (often enough to bet on, anyway). Answering questions for careless and sloppy thinkers is not rewarding; we'd rather spend our time elsewhere.


So expressing your question clearly and well is important. If you can't be bothered to do that, we can't be bothered to pay attention. Spend the extra effort to polish your language. It doesn't have to be stiff or formal — in fact, hacker culture values informal, slangy and humorous language used with precision. But it has to be precise; there has to be some indication that you're thinking and paying attention.


Spell, punctuate, and capitalize correctly. Don't confuse its with it's, loose with lose, or discrete with discreet. Don't TYPE IN ALL CAPS; this is read as shouting and considered rude. (All-smalls is only slightly less annoying, as it's difficult to read. Alan Cox can get away with it, but you can't.)


More generally, if you write like a semi-literate boob you will very likely be ignored. So don't use instant-messaging shortcuts. Spelling "you" as "u" makes you look like a semi-literate boob to save two entire keystrokes. Worse: writing like a l33t script kiddie hax0r is the absolute kiss of death and guarantees you will receive nothing but stony silence (or, at best, a heaping helping of scorn and sarcasm) in return.


If you are asking questions in a forum that does not use your native language, you will get a limited amount of slack for spelling and grammar errors — but no extra slack at all for laziness (and yes, we can usually spot that difference). Also, unless you know what your respondent's languages are, write in English. Busy hackers tend to simply flush questions in languages they don't understand, and English is the working language of the Internet. By writing in English you minimize your chances that your question will be discarded unread.


If you are writing in English but it is a second language for you, it is good form to alert potential respondents to potential language difficulties and options for getting around them. Examples:





  • English is not my native language; please excuse typing errors.




  • If you speak $LANGUAGE, please email/PM me; I may need assistance translating my question.




  • I am familiar with the technical terms, but some slang expressions and idioms are difficult for me.




  • I've posted my question in $LANGUAGE and English. I'll be glad to translate responses, if you only use one or the other.










Send questions in accessible, standard formats





If you make your question artificially hard to read, it is more likely to be passed over in favor of one that isn't. So:





  • Send plain text mail, not HTML. (It's not hard to turn off HTML.) Further discussion of why this is good practice can be found here and here.




  • MIME attachments are usually OK, but only if they are real content (such as an attached source file or patch), and not merely boilerplate generated by your mail client (such as another copy of your message).




  • Don't send e-mail in which entire paragraphs are single multiply-wrapped lines. (This makes it too difficult to reply to just part of the message.) Assume that your respondents will be reading mail on 80-character-wide text displays and set your line wrap accordingly, to something less than 80.




  • However, do not wrap data (such as log file dumps or session transcripts) at any fixed column width. Data should be included as-is, so respondents can have confidence that they are seeing what you saw.




  • Don't send MIME Quoted-Printable encoding to an English-language forum. This encoding can be necessary when you're posting in a language ASCII doesn't cover, but many e-mail agents don't support it. When they break, all those =20 glyphs scattered through the text are ugly and distracting — or may actively sabotage the semantics of your text.




  • Never, ever expect hackers to be able to read closed proprietary document formats like Microsoft Word or Excel. Most hackers react to these about as well as you would to having a pile of steaming pig manure dumped on your doorstep. Even when they can cope, they resent having to do so.




  • If you're sending e-mail from a Windows machine, turn off Microsoft's problematic Smart Quotes feature (From Tools > AutoCorrect Options, clear the smart quotes checkbox under AutoFormat As You Type.). This is so you'll avoid sprinkling garbage characters through your mail.




  • In Web forums, do not abuse smiley and HTML features (when they are present). A smiley or two is usually OK, but colored fancy text tends to make people think you are lame. Seriously overusing smileys and color and fonts will make you come off like a giggly teenage girl, which is not generally a good idea unless you are more interested in sex than answers.





If you're using a graphical-user-interface mail client such as Netscape Messenger, MS Outlook, or their ilk, beware that it may violate these rules when used with its default settings. Most such clients have a menu-based View Source command. Use this on something in your sent-mail folder, verifying sending of plain text without unnecessary attached crud.







Be precise and informative about your problem








  • Describe the symptoms of your problem or bug carefully and clearly.




  • Describe the environment in which it occurs (machine, OS, application, whatever). Provide your vendor's distribution and release level (e.g.: Fedora Core 7, Slackware 9.1, etc.).




  • Describe the research you did to try and understand the problem before you asked the question.




  • Describe the diagnostic steps you took to try and pin down the problem yourself before you asked the question.




  • Describe any possibly relevant recent changes in your computer or software configuration.




  • If at all possible, provide a way to reproduce the problem in a controlled environment.





Do the best you can to anticipate the questions a hacker will ask, and answer them in advance in your request for help.


Giving hackers the ability to reproduce the problem in a controlled environment is especially important if you are reporting something you think is a bug in code. When you do this, your odds of getting a useful answer and the speed with which you are likely to get that answer both improve tremendously.


Simon Tatham has written an excellent essay entitled How to Report Bugs Effectively. I strongly recommend that you read it.







Volume is not precision





You need to be precise and informative. This end is not served by simply dumping huge volumes of code or data into a help request. If you have a large, complicated test case that is breaking a program, try to trim it and make it as small as possible.


This is useful for at least three reasons. One: being seen to invest effort in simplifying the question makes it more likely you'll get an answer, Two: simplifying the question makes it more likely you'll get a useful answer. Three: In the process of refining your bug report, you may develop a fix or workaround yourself.







Don't rush to claim that you have found a bug





When you are having problems with a piece of software, don't claim you have found a bug unless you are very, very sure of your ground. Hint: unless you can provide a source-code patch that fixes the problem, or a regression test against a previous version that demonstrates incorrect behavior, you are probably not sure enough. This applies to webpages and documentation, too; if you have found a documentation bug, you should supply replacement text and which pages it should go on.


Remember, there are many other users that are not experiencing your problem. Otherwise you would have learned about it while reading the documentation and searching the Web (you did do that before complaining, didn't you?). This means that very probably it is you who are doing something wrong, not the software.


The people who wrote the software work very hard to make it work as well as possible. If you claim you have found a bug, you'll be impugning their competence, which may offend some of them even if you are correct. It's especially undiplomatic to yell bug in the Subject line.


When asking your question, it is best to write as though you assume you are doing something wrong, even if you are privately pretty sure you have found an actual bug. If there really is a bug, you will hear about it in the answer. Play it so the maintainers will want to apologize to you if the bug is real, rather than so that you will owe them an apology if you have messed up.







Grovelling is not a substitute for doing your homework





Some people who get that they shouldn't behave rudely or arrogantly, demanding an answer, retreat to the opposite extreme of grovelling. I know I'm just a pathetic newbie loser, but.... This is distracting and unhelpful. It's especially annoying when it's coupled with vagueness about the actual problem.


Don't waste your time, or ours, on crude primate politics. Instead, present the background facts and your question as clearly as you can. That is a better way to position yourself than by grovelling.


Sometimes Web forums have separate places for newbie questions. If you feel you do have a newbie question, just go there. But don't grovel there either.







Describe the problem's symptoms, not your guesses





It's not useful to tell hackers what you think is causing your problem. (If your diagnostic theories were such hot stuff, would you be consulting others for help?) So, make sure you're telling them the raw symptoms of what goes wrong, rather than your interpretations and theories. Let them do the interpretation and diagnosis. If you feel it's important to state your guess, clearly label it as such and describe why that answer isn't working for you.


Stupid:

I'm getting back-to-back SIG11 errors on kernel compiles, and suspect a hairline crack on one of the motherboard traces. What's the best way to check for those?


Smart:

My home-built K6/233 on an FIC-PA2007 motherboard (VIA Apollo VP2 chipset) with 256MB Corsair PC133 SDRAM starts getting frequent SIG11 errors about 20 minutes after power-on during the course of kernel compiles, but never in the first 20 minutes. Rebooting doesn't restart the clock, but powering down overnight does. Swapping out all RAM didn't help. The relevant part of a typical compile session log follows.



Since the preceding point seems to be a tough one for many people to grasp, here's a phrase to remind you: "All diagnosticians are from Missouri." That US state's official motto is "Show me" (earned in 1899, when Congressman Willard D. Vandiver said "I come from a country that raises corn and cotton and cockleburs and Democrats, and frothy eloquence neither convinces nor satisfies me. I'm from Missouri. You've got to show me.") In diagnosticians' case, it's not a matter of skepticism, but rather a literal, functional need to see whatever is as close as possible to the same raw evidence that you see, rather than your surmises and summaries. Show us.







Describe your problem's symptoms in chronological order





The clues most useful in figuring out something that went wrong often lie in the events immediately prior. So, your account should describe precisely what you did, and what the machine and software did, leading up to the blowup. In the case of command-line processes, having a session log (e.g., using the script utility) and quoting the relevant twenty or so lines is very useful.


If the program that blew up on you has diagnostic options (such as -v for verbose), try to select options that will add useful debugging information to the transcript. Remember that more is not necessarily better; try to choose a debug level that will inform rather than drowning the reader in junk.


If your account ends up being long (more than about four paragraphs), it might be useful to succinctly state the problem up top, then follow with the chronological tale. That way, hackers will know what to watch for in reading your account.







Describe the goal, not the step





If you are trying to find out how to do something (as opposed to reporting a bug), begin by describing the goal. Only then describe the particular step towards it that you are blocked on.


Often, people who need technical help have a high-level goal in mind and get stuck on what they think is one particular path towards the goal. They come for help with the step, but don't realize that the path is wrong. It can take substantial effort to get past this.


Stupid:

How do I get the color-picker on the FooDraw program to take a hexadecimal RGB value?


Smart:

I'm trying to replace the color table on an image with values of my choosing. Right now the only way I can see to do this is by editing each table slot, but I can't get FooDraw's color picker to take a hexadecimal RGB value.



The second version of the question is smart. It allows an answer that suggests a tool better suited to the task.







Don't ask people to reply by private e-mail





Hackers believe solving problems should be a public, transparent process during which a first try at an answer can and should be corrected if someone more knowledgeable notices that it is incomplete or incorrect. Also, helpers get some of their reward for being respondents from being seen to be competent and knowledgeable by their peers.


When you ask for a private reply, you are disrupting both the process and the reward. Don't do this. It's the respondent's choice whether to reply privately — and if he does, it's usually because he thinks the question is too ill-formed or obvious to be interesting to others.


There is one limited exception to this rule. If you think the question is such that you are likely to get many answers that are all closely similar, then the magic words are e-mail me and I'll summarize the answers for the group. It is courteous to try and save the mailing list or newsgroup a flood of substantially identical postings — but you have to keep the promise to summarize.







Be explicit about your question





Open-ended questions tend to be perceived as open-ended time sinks. Those people most likely to be able to give you a useful answer are also the busiest people (if only because they take on the most work themselves). People like that are allergic to open-ended time sinks, thus they tend to be allergic to open-ended questions.


You are more likely to get a useful response if you are explicit about what you want respondents to do (provide pointers, send code, check your patch, whatever). This will focus their effort and implicitly put an upper bound on the time and energy a respondent must allocate to helping you. This is good.


To understand the world the experts live in, think of expertise as an abundant resource and time to respond as a scarce one. The less of a time commitment you implicitly ask for, the more likely you are to get an answer from someone really good and really busy.


So it is useful to frame your question to minimize the time commitment required for an expert to field it — but this is often not the same thing as simplifying the question. Thus, for example, Would you give me a pointer to a good explanation of X? is usually a smarter question than Would you explain X, please?. If you have some malfunctioning code, it is usually smarter to ask for someone to explain what's wrong with it than it is to ask someone to fix it.







When asking about code





Don't ask others to debug your broken code without giving a hint what sort of problem they should be searching for. Posting a few hundred lines of code, saying "it doesn't work", will get you ignored. Posting a dozen lines of code, saying "after line 7 I was expecting to see , but occurred instead" is much more likely to get you a response.


The most effective way to be precise about a code problem is to provide a minimal bug-demonstrating test case. What's a minimal test case? It's an illustration of the problem; just enough code to exhibit the undesirable behavior and no more. How do you make a minimal test case? If you know what line or section of code is producing the problematic behavior, make a copy of it and add just enough supporting code to produce a complete example (i.e. enough that the source is acceptable to the compiler/interpreter/whatever application processes it). If you can't narrow it down to a particular section, make a copy of the source and start removing chunks that don't affect the problematic behavior. The smaller your minimal test case is, the better (see the section called “Volume is not precision”).


Generating a really small minimal test case will not always be possible, but trying to is good discipline. It may help you learn what you need to solve the problem on your own — and even when it doesn't, hackers like to see that you have tried. It will make them more cooperative.


If you simply want a code review, say as much up front, and be sure to mention what areas you think might particularly need review and why.