The election of 1800 was the first in which the contingent election procedures of the Constitution were put to the test and the president was elected by the House.The election was tied between Thomas Jefferson and Aaron Burr for reasons worth checking out and after some serious politicking Jefferson wound up president.
The question (& answer) were found on p. 13-14 of Presidential Elections: 1789-1992. The book was published by the Congressional Quarterly in 1995.