Related: Concepts MOC
when something goes wrong - it’s an opportunity to learn
- programming is problem-solving
- bugs and defects are potentials to pick up new skills and improve something
You will learn more via doing (and failing) vs if you get something right on the first try
According to research, when people make wrong guesses and are then corrected, they’re more likely to remember the correct answer in the future. This is not always a guaranteed way of learning though - you must pay attention and process the correction!
The default way of learning is to try a solution, see that the solution fails, and repeat until you find something that works. It’s better than nothing, but it’s better to have a framework. This leads to solving problems efficiently AND working out your problem-solving muscle.
General framework
- Understand: what exactly is the problem? Explain it in plain language. This steps alone gets you pretty far!
- Plan: “If X is the input, what steps need to happen to get Y as the output?”
- Divide: Break it down into smaller problems that can be solved independently. Solve each small problem, and then connect them together.
- Take a break/shift perspective: If you get stuck, start debugging. Go through your solution step by step. Take a break and look at it from a different angle.
- Don’t be afraid to google! If you’re really wanting to learn, only google the solutions to your subproblems, not the overall question you want to answer!
Can contribute to spiral learning