Depends on what kind of mentor. A lot of times, having someone who knows tips and tricks or has seen the problem before can be really helpful. Even just watching how someone else does it can be helpful.
For example, at work we have tests written in C in the 90s to 2000s to control equipment and test our products. The way some of the new test engineers and interns would fix things would be to change a parameter and recompile the test, instead of adding a variable to the watch window, using breakpoints, stepping through functions, etc. Showing them that those tools existed was huge for troubleshooting problems whenever something breaks (which is often).
The bad kind of mentor is one who doesn't/cant explain why doing it one way may have tradeoffs as opposed to the way you would do it. Their job is to 1) set an example for good practices and 2) guide you when you are doing something in a less efficient or self sabotaging way.
Especially with C work, I explain that adding debugging statements may obfuscate the bug they're trying to find because of the changed memory map, especially if the bug is arising from an over/underwrite