The classic version of this is “How to ask questions the smart way”.
I would also add: be ready to be questioned back with “What is it that you’re trying to do” when presenting an expert with a possible solution. Chances are you’re trying to solve a problem in a very roundabout way, and there is a more idiomatic, better way to solve your problem. So don’t be shy in describing your end goal.
Don’t forget to describe your constraints along with your goal. Otherwise you might get very unhelpful answers.
The corollary: if you’re mentoring junior devs and want them to work this way, hold (maybe as a rotation with other mentors) a regular surgery/office hours session to make it clear that you’re available regularly and questions are welcome, particularly at the agreed time.