How to help a programming student get unstuck
Hell, it’s Saturday and I feel talkative.  If somebody is stuck, several steps come to mind:<p>Do they understand the problem(s) they’re being asked to solve?  Toy or otherwise, this strikes me as a necessary condition.<p>Can they express their solution in discrete steps?  Software is brilliantly stupid, and must be told in detail what to do.  This step should be independent of language, and is more of a logic exercise.<p>Can they express their “discrete steps” in the language(s) that are required.  This is an engineering problem that can be solved with references, practice, etc.  Perhaps we can think of the steps stage as writing in ones native language and the implementation stage as writing in a nonnative tongue.<p>Debugging.  This is a generally applicable skill for any multi step problem.  In the case of software there is language and hardware issues in addition to logic and understanding the problem space that usually make things worse.  But I have found that if these two aspects can be separated things go much better than blurring the two.<p>If needed, tuning can be seen as both a (re)design or additional debugging step which is outside the initial discussion.  But aside from design, one should separate making something work vs. work fast unless they have a very good grasp of their problem and solution.  Much of what we do is separable, as things like abstractions are so useful.<p>If a student is struggling, the mentor can help them determine which step they are hung up on and the kind of nudging that would be most helpful.  People who can create sound, stepwise solutions are useful - they can apply this to pretty much any environment.  Knowing the nooks and crannies of a language without good logic&#x2F;design merely creates hard to maintain code.