Ask HN: How to Teach Coding?
51–60 of 126 posts
Re: Ask HN: How to Teach Coding?
#52I've found the most valuable thing is often good, uncluttered examples. Docs are often focused entirely on the API's but don't have enough to show you how to use them, and Google/SO can be a rabbit hole of examples that are overcomplicated or misleading.
"Try something like this" (with comments) goes a long way.
So much of being a beginner is not having been exposed to patterns and techniques. They need to fill our their toolbox, and in doing that, make sure to walk through what the code does and why, since nobody benefits from cargo-culting.
Let's see, also...
1. Teach interactive shell and debugging early. It's life changing.
2. Make sure to assign them entire projects. The fastest way to burn out a beginner is give them a series of small tasks in code they don't really understand.
3. Chill out on code review. Limit yourself to a few suggestions for each PR. If you offer two suggestions and rationale, they might say "aha, that makes sense" and remember that. If you offer 15, nothing will stick.
Re: Ask HN: How to Teach Coding?
#531. Tell them what to do but do not tell them how to do it. (Just give a few pointers otherwise they'll be lost.) 2. Give them a playground to fail - Offload any non-business critical tasks and let them make mistakes. No one I know ever learnt programming without making any mistakes. Immediately tell them about best practices and how to avoid such mistakes in future. 3. Show them the impact of their work - There's not…
"No one I know ever learnt programming without making any mistakes." True! In fact, I don't know anyone who programs without making any mistake.
Re: Ask HN: How to Teach Coding?
#54Re: Ask HN: How to Teach Coding?
#55We need people like you. All the best!
Re: Ask HN: How to Teach Coding?
#56It depends on what you’re teaching though. If it’s bringing a new hire up to speed what works best for us is to give them access to a portfolio of how we do things and let them hack away at a problem on their own. If they have questions we help, and their mentor makes sure they aren’t stuck and afraid to ask.
The sad fact is that 95% of our learning curve is figuring out how the damn toolset is used, and it only 5% of what’s hard is actually programming. I’m sure it’s different if you’re a PhD at google, but in our shop we rarely invent new CS concepts, so it’s mostly about learning how to make tools work. We’ll get people who know JavaScript and .Net who have no idea how to deploy it on our IIS servers, or how to setup the config file so only a specific AD group has access to a specific API, stuff like that. I’m not sure where it all went wrong, but it did.
Re: Ask HN: How to Teach Coding?
#57- Use stack to program how to escape a maze.
- Teach Functional Programming, and optional OOP.
Re: Ask HN: How to Teach Coding?
#58When teaching people to write code I try to get them to practice thinking about writing instructions. Actually practicing their writing skills. The important part of that is that they struggle through the thinking process of finding a solution as a series of pieces and that they communicate that solution clearly.
What I want them to avoid is them thinking about programming as lego pieces they put together, because that becomes their expectation and reality. The problem with this is that when a person limits their expectation to putting things together and they move from education to employment they tend to be really good at configuring things and really bad at writing original code.
Re: Ask HN: How to Teach Coding?
#59Re: Ask HN: How to Teach Coding?
#601. Tell them what to do but do not tell them how to do it. (Just give a few pointers otherwise they'll be lost.) 2. Give them a playground to fail - Offload any non-business critical tasks and let them make mistakes. No one I know ever learnt programming without making any mistakes. Immediately tell them about best practices and how to avoid such mistakes in future. 3. Show them the impact of their work - There's not…
I think even more importantly is to encourage failure, or at least reporting it. How many times have you been ecstatic that you managed to get a program to crash differently? A lot of people are terrified of failure, but people probably learn better from their mistakes. And showing them that it's ok (even encouraged) to report what their stuck on to you means that they can potentially get a quicker solution, learn from you.