Your vehicle has three choices: Swerve left into oncoming traffic, which will almost certainly kill you. Swerve right across a sidewalk and you dive over an embankment, where the fall will most likely kill you. Or continue straight ahead, which would save your life, but most likely kill a few kids along the way.
Self Driving Cars Are Not “Five Years Away.”
John Battelle

Or, it’s not a problem as vehicles shouldn’t be doing more than 20mph anyway, and so could react in time easily (as well as the fact they could and should be made of very different lightweight, softer materials.) Our conception of what driving is has to change; it’s absurd that vehicles should be moving quickly in built-up environments. The greater issue concerns reducing ‘vehicle miles travelled’ in the first place, and hence the speed by which things need to move, by shifting patterns of development so we live closer to where we work, play etc. That is where your starting premise feels right; this is not a five year challenge, at least in the USA and similar, but a 20 year shift. The issue isn’t the Trolley Problem, which is linked to an old idea of driving quickly, but rather concerns how we shift to mixed-use, medium density places, with their associated patterns of living that preference social interaction, good health, cleaner greener environments and quality of place over being able to drive long distances. The numerous and diverse benefits that would accrue from that shift make this entirely possible. That’s the real goal here. AVs could well be part of that shift – in fourth place behind walking, cycling and good mass transit, mopping up in the gaps – but seen in isolation, won’t really get us anywhere, ironically enough.