It is a good mechanism to start to ask a question.
First, get your stuff together: work out exactly what your problem is (compiler error, runtime error, unexpected results) and narrow down what part of the code you think is causing it (or for nonprogramming sites, the equivalents to these two.) This often is all it takes for you to solve some problems.
Second, search using some of the keywords you think might be the problem. Use Google or the site search. You'll have more keywords because you took the time to get your stuff together first. Maybe you'll find what you need.
Third, click Ask a Question and start asking - but don't post the question! As you write the question, above the text entry box you will see similar questions. Open those in a new tab and read them carefully. If they solve your problem, vote up the question and any useful answers, and abandon your question without posting it. If the answer would solve your question, but there are no answers, consider setting a bounty, and again, abandon your question. If they don't solve your problem but others might see yours as a dupe, add a pre-emptive "I have read [link] and this is different because [reasons]" to your question.
After you've read all the related questions and made yours as crisp and complete as possible, should you still not know the answer, post your question. It may still be a duplicate, but you will have created a useful signpost to lead other people to that other question in the future.