Often we see a question which is not really handled on Arduino Stack Exchange because, for example, a solution may involve some electronics in addition to Arduino know how or, in some other way, is not regarded as a pure Arduino matter. Usually, such questions would be a good candidate for forum.arduino.cc . The question is, is it good form to say so so explicitly to the OP ?
Bear in mind that beginners may not know what it is that they don't know (for example, it is fairly common for them not to know the Arduino is programmed using C++).
Plus, the idea of things being "pure" Arduino are a little hard to quantify. After all, most problems have some elements of programming in them, some elements of electronics, and some elements of simple debugging and problem solving.
My personal approach is to help people as much as I can, even if a question is largely about C++ or electronics, unless the question doesn't seem to have any relationship at all to the Arduino. And I don't try quite so hard for questions that seem to be "here is my homework assignment, please do it for me ... and I'm in a hurry, it is due tonight".
Step-by-step debugging where the OP gets asked dozens of questions, given things to try, and report the results are better suited to a forum than Stack Exchange. If a question is heading down that path it could be a good time to suggest that the forum format is better suited to solving their problem.
Very few questions will not be "borderline off-topic". I have to agree with @NickGammon that whether we're hobbyists, experimenters, engineers acquiring a new skill-set, etc., very few problems fit compactly into "Arduino" or "not-Arduino". Can't we just try to be helpful before - or instead of - looking down our noses at the newcomer? Are we here to help our them? Or to posture before each other? Are we a community, or a collection of egos showing off what we know? Should ASE to be a welcoming place for people to learn or a group of elitists who might tolerate a newcomer if they figure out The Right Way to ask a question? I see a lot of responses to newcomers, even to knowledgeable ones that didn't write a question in the One True Way. that could send anybody walking, muttering to themselves about how unfriendly ASE is.
It doesn't have to be this way. But it will need the mods setting a friendly example and taking a firm stance on unfriendly & unhelpful replies toward newcomers by ASE members. Sure, if a question is a better fit for another SE (or non-SE) group, by all means, suggest it and in a helpful way. But why not welcome newcomers with a more friendly stance (yes, some do, but not all) and a more liberal interpretation of what fits here?