Why did the United States sell arms to Iran in the 1980s?

to oust Iran’s Communist government from power
to prevent the Soviets from winning control of Iran
to obtain the release of the hostages
to get revenge for the bombing of American marine barracks

The United States sold arms to Iran in the 1980s in order to obtain the release of hostages who were being held in Lebanon by Iranian-backed militants. This covert operation, known as the Iran-Contra affair, involved trading arms for hostages and using the proceeds to fund anti-Communist rebels in Nicaragua. It was a complex and controversial strategy that ultimately led to a political scandal for the Reagan administration.