This is really just another instance of an ethical dilemma that humanity has faced forever. It has many illustrations but one that has been used in teaching ethics is called the "life boat" problem. If there is not enough room in the lifeboat for everyone, who gets in? If there is not enough food and water, who gets preference?
The simple answer is "women and children first." Human drivers will steer away from a woman with a baby carriage even if they do not have time to evaluate the alternative. It is built into the culture, all but automatic, but the reason is that it is pro life. Children are the future of the species. Women can nurture and reproduce. Men can sow but they cannot reap. While the male role takes minutes, the female role takes months. Life needs more females than males.
The reason that we do not apply this pro life rationale to the autonomous automobile is that we assume that the consideration is beyond its capability. However, most of what one expects of an autonomous car today was beyond its capability a decade ago. For the moment, most may not be able to consider all the factors we might like. For example, they may not recognize age and gender, much less consider them. Ten years from now, they certainly will.
In this context it is useful to consider how such systems make a decision. They identify a number of scenarios, depending upon the time available, assign an outcome and a confidence level to each, and choose statistically. The kind of ties implied by the strawman dilemma will be vanishingly rare, even more so as the computers become faster and the number of things the can consider increases.
Compare the autonomous car to the human driver. In the two tenths of a second that it takes a young adult to recognize and react, the autonomous car will evaluate dozens of possibilities with as many considerations. Like the human driver, the autonomous car may confront instances when there are simply no good options but the whole reason for using them is that they are less likely than the human driver to overlook the least damaging.