Practice makes perfect or thereabouts. Repeating activities will make sequencing these activities in real-world environments much simpler. Where mistakes are costly, prefer to learn in a sandbox environment.
There will always be some level of uncertainty in life. And the larger the reward the larger the risk. However you should always avoid unnecessary risks. In pursuit of your best work take opportunities to de-risk your plans where possible.
Contingency planning is a complex endeavor. That complexity stems from a future of countless possibilities. Being systematic in risk mitigation should involve establishing guardrails to broad categories of problem rather than focusing on any specific example.