The social solution
You should work on the relationship with your coworkers. The question was by definition not easy because you had to ask someone. Even if the solution turns out to be easy, you shouldn't be afraid of asking. Be proud of your questions: proud of the time you put into trying to solve the problem, proud of the time it took to formalize and put down your thoughts, and proud of you wanting to learn.
Any good programming environment should appreciate the value of helping each other. We cannot program in a vacuum, and nobody can know everything. We know stuff together, not by ourselves! If you believe your coworkers are smarter than you, try to ask them if you have any questions before going to Stack Overflow. Even questions that on the surface looks easy! Showing your weaknesses will usually strengthen your relationships, not weakening them. And I think you will realize that they, too, don't know everything, and they can help you develop your troubleshooting and answer-seeking skills.
And if you happen to be in an environment where asking questions can be detrimental to your career or social status, where people stab each others backs for asking "stupid" questions: Get out! It's not healthy to be there!