The trolley problem is a thought experiment in ethics. The general form of the problem is this: There is a runaway trolley barreling 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 pull this lever, the trolley will switch to a different set of tracks. However, you notice that there is one person on the side track. You have two options: (1) Do nothing, and the trolley kills the five people on the main track. (2) Pull the lever, diverting the trolley onto the side track where it will kill one person. Which is the most ethical choice?
The modern form of the problem was first introduced by Philippa Foot in 1967, but also extensively analysed by Judith Thomson,Frances Kamm, and Peter Unger. However an earlier version, in which the one person to be sacrificed on the track was the switchman's child, was part of a moral questionnaire given to undergraduates at the University of Wisconsin in 1905, and the German Hans Welzel discussed a similar problem in 1951. Outside of the domain of traditional philosophical discussion, the trolley problem has been a significant feature in the fields of cognitive science and, more recently, of neuroethics. It has also been a topic in popular books dealing with human psychology. The problem is also discussed with regards to the ethics of the design of autonomous vehicles.
Foot's original structure of the problem ran as follows:
Suppose that a judge or magistrate is faced with rioters demanding that a culprit be found for a certain crime and threatening otherwise to take their own bloody revenge on a particular section of the community. The real culprit being unknown, the judge sees himself as able to prevent the bloodshed only by framing some innocent person and having him executed. Beside this example is placed another in which a pilot whose airplane is about to crash is deciding whether to steer from a more to a less inhabited area. To make the parallel as close as possible it may rather be supposed that he is the driver of a runaway tram which he can only steer from one narrow track on to another; five men are working on one track and one man on the other; anyone on the track he enters is bound to be killed. In the case of the riots the mob have five hostages, so that in both examples the exchange is supposed to be one man's life for the lives of five.