Understanding how to reflect on and learn from failures and mistakes can help improve motivation and performance.