Modern technology lets you hack this problem away!
In most parts of the world, weather forecasting is performed at least daily, and in many places you can get accurate hour-by-hour predictions. One of the main things they try to predict is whether there will be precipitation. As you can see from this study, the best predictors as of 7 years ago were bordering on 90% accuracy one day off, and it's only gotten better since. You can check forecasts on any device with an internet connection, such as a computer or a smartphone. You can also check them via TV or radio if those are more readily available.
That means that 90% of the time, you can avoid this trouble by checking the weather forecasts, which should not take more than a few seconds in the morning. If there's anything more than a 10% chance of rain, just bring an umbrella and you've pre-hacked the system to avoid your troubles. You can do better by checking closer to the time you need to be outside, since forecasts generally do better the closer you are.
In addition, if you frequently go to certain places other than your home (e.g. your office) you can leave an umbrella in each of them. This will allow you to check right before you have to go outside again, which gives you the benefit of the most up-to-date forecasts. The only downside is that you'll have to carry the umbrella back with you, but that's not anywhere near as bad as being caught in the rain without one.
As an alternative to an umbrella, you could keep a poncho in your pocket. Disposable ponchos are available for as low as 1 USD and easily fit in even a small pocket. A garbage bag with a hole for your head will work as well if you're desperate. These are good options if umbrellas are not acceptable for any reason.