<P> Eight presidents served during World War II, while seven served in the military during the American Civil War . </P> <P> The following list outlines the military service of each president before becoming the commander in chief . </P> <Table> <Tr> <Th> President </Th> <Th> Service </Th> <Th> Rank </Th> <Th> Active Service </Th> </Tr> <Tr> <Td> Donald Trump </Td> <Td> None </Td> <Td> None </Td> <Td> None </Td> </Tr> <Tr> <Td> Barack Obama </Td> <Td> None </Td> <Td> None </Td> <Td> None </Td> </Tr> <Tr> <Td> George W. Bush </Td> <Td> Texas Air National Guard, United States Air Force </Td> <Td> First Lieutenant </Td> <Td> Stateside service as pilot during Vietnam War (1968--1973). (See George W. Bush military service controversy) </Td> </Tr> <Tr> <Td> Bill Clinton </Td> <Td> None </Td> <Td> None </Td> <Td> None . Received student draft deferments, and planned to join Reserve Officers' Training Corps . Withdrew and entered draft, but received high number and was not drafted . (See Bill Clinton: Vietnam War opposition and draft controversy .) </Td> </Tr> <Tr> <Td> George H.W. Bush </Td> <Td> United States Naval Reserve </Td> <Td> Lieutenant (Junior Grade) </Td> <Td> Naval aviator in World War II (1942--1945). Shot down and received the Distinguished Flying Cross . </Td> </Tr> <Tr> <Td> Ronald Reagan </Td> <Td> United States Army Reserve, United States Army Air Forces </Td> <Td> Captain </Td> <Td> Stateside service during World War II (1942--1945); Army Reserve (1937--1942). </Td> </Tr> <Tr> <Td> Jimmy Carter </Td> <Td> United States Navy </Td> <Td> Lieutenant (navy) </Td> <Td> Served during World War II as a midshipman at the United States Naval Academy . Sea duty and stateside service 1946--1953 during the Korean War . </Td> </Tr> <Tr> <Td> Gerald Ford </Td> <Td> United States Naval Reserve </Td> <Td> Lieutenant Commander </Td> <Td> World War II (1942--1945); combat on USS Monterey, discharged in 1946 . </Td> </Tr> <Tr> <Td> Richard Nixon </Td> <Td> United States Naval Reserve </Td> <Td> Commander </Td> <Td> World War II (1942--1945); earned two battle stars for service in the Pacific . </Td> </Tr> <Tr> <Td> Lyndon B. Johnson </Td> <Td> United States Naval Reserve </Td> <Td> Commander </Td> <Td> World War II received Silver Star medal after observation mission in which aircraft he was on allegedly came under Japanese attack . However, new evidence has come to light proving that the plane in fact developed mechanical problems and therefore turned around, having never come under fire . Johnson was the only member of the crew to receive a decoration, therefore leading historians to conclude that General MacArthur awarded him this to secure political influence . </Td> </Tr> <Tr> <Td> John F. Kennedy </Td> <Td> United States Naval Reserve </Td> <Td> Lieutenant (navy) </Td> <Td> Served in combat during World War II . Received the Navy and Marine Corps Medal and the Purple Heart . </Td> </Tr> <Tr> <Td> Dwight D. Eisenhower </Td> <Td> United States Army </Td> <Td> General of the Army </Td> <Td> Stateside service during World War I. Served as Supreme Allied Commander in Europe during World War II (1942--1945). Entire active - duty career spanned from 1915 until 1969 (excepting his two terms as president). </Td> </Tr> <Tr> <Td> Harry S. Truman </Td> <Td> Missouri Army National Guard, United States Army, United States Army Reserve </Td> <Td> Colonel </Td> <Td> Stateside National Guard service in Missouri (1905--1911); served in combat in France during World War I (1917--1918); transferred to Army Reserve and retired in 1953 . </Td> </Tr> <Tr> <Td> Franklin D. Roosevelt </Td> <Td> None </Td> <Td> None </Td> <Td> None; Assistant Secretary of the Navy during World War I . </Td> </Tr> <Tr> <Td> Herbert Hoover </Td> <Td> None </Td> <Td> None </Td> <Td> None; helped guide US Marines in 1900 during the Boxer Rebellion . </Td> </Tr> <Tr> <Td> Calvin Coolidge </Td> <Td> None </Td> <Td> None </Td> <Td> None </Td> </Tr> <Tr> <Td> Warren G. Harding </Td> <Td> None </Td> <Td> None </Td> <Td> None </Td> </Tr> <Tr> <Td> Woodrow Wilson </Td> <Td> None </Td> <Td> None </Td> <Td> None </Td> </Tr> <Tr> <Td> William Howard Taft </Td> <Td> Connecticut Home Guard </Td> <Td> None </Td> <Td> None; United States Secretary of War 1904--1908 . Enlisted in Connecticut Home Guard for World War I. Was chairman of American Red Cross executive committee during World War I. President Wilson conferred military titles on Red Cross leaders to provide them authority to carry out their wartime responsibilities, and Taft was appointed a major general . </Td> </Tr> <Tr> <Td> Theodore Roosevelt </Td> <Td> United States Army </Td> <Td> Colonel </Td> <Td> New York National Guard, 1882 to 1886, captain and company commander . Spanish--American War service as second in command and then commander of the 1st United States Volunteer Cavalry (Rough Riders). Only U.S. President to receive the Medal of Honor (awarded posthumously in 2001). Also a Navy Civilian, as Assistant Secretary of the Navy </Td> </Tr> <Tr> <Td> William McKinley </Td> <Td> United States Army </Td> <Td> Brevet Major </Td> <Td> American Civil War . Served in the 23rd Ohio Infantry under future President Rutherford B. Hayes; fought in the Battle of South Mountain, The Battle of Antietam, and in the Valley Campaigns of 1864 . </Td> </Tr> <Tr> <Td> Benjamin Harrison </Td> <Td> United States Army </Td> <Td> Brigadier General </Td> <Td> American Civil War; Commanded an Infantry Brigade at the battles of Resaca, New Hope Church, Kennesaw Mountain, Marietta, Peachtree Creek and Atlanta; also Commanded a brigade during Sherman's March to the Sea . </Td> </Tr> <Tr> <Td> Grover Cleveland </Td> <Td> None </Td> <Td> None </Td> <Td> None . </Td> </Tr> <Tr> <Td> Chester A. Arthur </Td> <Td> New York State Militia </Td> <Td> Brigadier General </Td> <Td> Judge Advocate General, Second Brigade of the New York Militia . Served as Engineer - in - Chief on the Governor's staff, Quartermaster General and Inspector General of the New York Militia before and during the American Civil War . Declined appointment as commander of the 9th New York Volunteer Infantry Regiment and command of four New York City regiments organized as the Metropolitan Brigade when Governor requested he remain Quartermaster General . </Td> </Tr> <Tr> <Td> James Garfield </Td> <Td> United States Army </Td> <Td> Major General </Td> <Td> American Civil War (1861--1863; commanded an Ohio Infantry Brigade at the Battles of Shiloh and Corinth; served as Chief of Staff for General William Rosecrans at the Battle of Chickamauga; left the army to serve in the United States House of Representatives). </Td> </Tr> <Tr> <Td> Rutherford B. Hayes </Td> <Td> United States Army </Td> <Td> Major General </Td> <Td> American Civil War . Served in the 23rd Ohio Infantry and commanded future President William McKinley; wounded at the Battle of South Mountain; also served at the Battle of Antietam and in the Valley Campaigns of 1864 . </Td> </Tr> <Tr> <Td> Ulysses S. Grant </Td> <Td> United States Army </Td> <Td> General of the Army </Td> <Td> Mexican--American War and American Civil War; served 1843--54 and 1861--68 . </Td> </Tr> <Tr> <Td> Andrew Johnson </Td> <Td> United States Army </Td> <Td> Brigadier General </Td> <Td> Served in Tennessee Militia in 1830s . American Civil War; served as Military Governor of Tennessee in 1862 . </Td> </Tr> <Tr> <Td> Abraham Lincoln </Td> <Td> Illinois State Militia </Td> <Td> Captain </Td> <Td> Black Hawk War (served three months in 1832); see Abraham Lincoln in the Black Hawk War . </Td> </Tr> <Tr> <Td> James Buchanan </Td> <Td> Pennsylvania State Militia </Td> <Td> Private </Td> <Td> War of 1812 </Td> </Tr> <Tr> <Td> Franklin Pierce </Td> <Td> United States Army </Td> <Td> Brigadier General </Td> <Td> New Hampshire Militia, 1831--46; Mexican--American War; commanded Infantry Brigade at Battle of Contreras (where his leg was injured), Battle of Churubusco, and the Assault on Mexico City . </Td> </Tr> <Tr> <Td> Millard Fillmore </Td> <Td> New York State Militia </Td> <Td> Major </Td> <Td> Served in New York Militia in 1820s and 1830s; Organized Union Continentals home guard unit in Buffalo, New York during the American Civil War . </Td> </Tr> <Tr> <Td> Zachary Taylor </Td> <Td> United States Army </Td> <Td> Major General </Td> <Td> War of 1812, Black Hawk War, Second Seminole War, Mexican--American War; entire career spanned from 1808 until 1848 . </Td> </Tr> <Tr> <Td> James K. Polk </Td> <Td> Tennessee State Militia </Td> <Td> Colonel </Td> <Td> Joined cavalry unit in Tennessee Militia as a Captain . Subsequently appointed a Colonel on the staff of Governor William Carroll . </Td> </Tr> <Tr> <Td> John Tyler </Td> <Td> Virginia militia </Td> <Td> Captain </Td> <Td> War of 1812 . </Td> </Tr> <Tr> <Td> William Henry Harrison </Td> <Td> United States Army </Td> <Td> Major General </Td> <Td> Northwest Indian War, War of 1812 . </Td> </Tr> <Tr> <Td> Martin Van Buren </Td> <Td> None </Td> <Td> None </Td> <Td> None . </Td> </Tr> <Tr> <Td> Andrew Jackson </Td> <Td> Tennessee State Militia, Continental Army, United States Army </Td> <Td> Major General </Td> <Td> American Revolutionary War, War of 1812, Creek War, First Seminole War . </Td> </Tr> <Tr> <Td> John Quincy Adams </Td> <Td> None </Td> <Td> None </Td> <Td> None </Td> </Tr> <Tr> <Td> James Monroe </Td> <Td> Continental Army </Td> <Td> Major </Td> <Td> American Revolutionary War; depicted holding the American flag behind General George Washington in the famous painting Washington Crossing the Delaware; wounded at the Battle of Trenton, depicted in the painting The Capture of the Hessians at Trenton, December 26, 1776 by John Trumbull . </Td> </Tr> <Tr> <Td> James Madison </Td> <Td> Virginia militia </Td> <Td> Colonel </Td> <Td> American Revolutionary War, did not see action . </Td> </Tr> <Tr> <Td> Thomas Jefferson </Td> <Td> Virginia militia </Td> <Td> Colonel </Td> <Td> Commander of Albemarle County Militia at start of American Revolution, did not see action . </Td> </Tr> <Tr> <Td> John Adams </Td> <Td> None </Td> <Td> None </Td> <Td> Adams served as chairman of the Continental Congress's Board of War (1776--77), making him the simultaneous equivalent of today's Secretary of Defense and Chairman of Senate Armed Services Committee; was a semi-participant in a naval engagement between a British and US ship during the American Revolution . </Td> </Tr> <Tr> <Td> George Washington </Td> <Td> Virginia militia, Virginia Regiment, Continental Army, United States Army </Td> <Td> Lieutenant General </Td> <Td> French and Indian War, American Revolutionary War . </Td> </Tr> </Table> <Tr> <Th> President </Th> <Th> Service </Th> <Th> Rank </Th> <Th> Active Service </Th> </Tr>

Who was the last us president to serve in the military
find me the text answering this question