"AI" wouldn't come up with that solution
...but I'll reiterate I think the trolley problem is a smokescreen and assumes the sensors would detect, parse, & recognize the situation correctly in the first place. Kind of conveniently glosses over the hardest part of the problem imho
Self driving cars will never work.