How will self-driving cars solve the trolley problem?

Recall the classic utilitarian morality puzzle (via Wikipedia): There is a runaway trolley barrelling down the railway tracks. Ahead, on the tracks, there are five people tied up and unable to move. The trolley is headed straight for them. You are standing some distance off in the train yard, next to a lever. If you …