It is a good question and I think it just requires forward planning. I have friends in Canada and it gets so cold there that even diesel will freeze. So every home is sold with a garage and every garage has a hook up for an engine block heater.
Likewise in New Mexico it is so arid and hot that you sweat without realising it and can quickly become dehydrated. So on the streets by the shops you would have water machines. You'd put in a dollar and it would cough out 2 litres of water or so.
I guess when you get consistent extremes society just adapts. In Moscow you have icicle engineers. They go around breaking the icicles off the edges of roofs to prevent people being killed by falling ones. In the same way they grit the roads here when it might be icy those guys clamber all over the roofs or use cherry pickers to break them down.
It is quite fascinating but also scary
RE: What If London Stays 40 °C For A Month?