Garfield's aptitude for mathematics extended to a notable proof of the Pythagorean theorem, which he published in 1876.
At the 1880 Republican National Convention, delegates chose Garfield, who had not sought the White House, as a compromise presidential nominee on the 36th ballot. In the 1880 presidential election, he conducted a low-key front porch campaign and narrowly defeated the Democratic nominee, Winfield Scott Hancock. Garfield's accomplishments as president included his resurgence of presidential authority against senatorial courtesy in executive appointments, a purge of corruption in the Post Office, and his appointment of a Supreme Court justice. He advocated for agricultural technology, an educated electorate, and civil rights for African Americans. He also proposed substantial civil service reforms, which were passed by Congress in 1883 as the Pendleton Civil Service Reform Act and signed into law by his successor, Chester A. Arthur.
Garfield was a member of the intraparty "Half-Breed" faction who used the powers of the presidency to defy the powerful "Stalwart" New York senator Roscoe Conkling. He did this by appointing Blaine faction leader William H. Robertson to the lucrative post of Collector of the Port of New York. 