title: James Monroe
context: James Monroe (/mənˈroʊ/; April 28, 1758 – July 4, 1831) was an American statesman and Founding Father who served as the fifth president of the United States from 1817 to 1825. He is perhaps best known for his foreign policy principle, known as the "Monroe Doctrine", which prohibited further European colonization of the Americas (beginning in 1823). Monroe was the last president of the Virginia dynasty, and his presidency ushered in what is known as the Era of Good Feelings. Born in Westmoreland County, Virginia, Monroe was of the planter class and fought in the American Revolutionary War. He was wounded in the Battle of Trenton with a musket ball to the shoulder. After studying law under Thomas Jefferson from 1780 to 1783, he served as a delegate in the Continental Congress.[1]
question: Who was president in 1817?
answers: James Monroe