General Robert E. Lee, son of Revolutionary War hero Henry "Light Horse Harry" Lee, graduated from the United States Military Academy at West Point in 1829, ranking second in a class of forty-six without a single demerit. Before the Civil War, his distinguished record included numerous engineering projects, service in the Mexican War, and nearly three years as commandant at West Point. In March and April 1861, he was offered command of the principal Union Army, but after Virginia seceded on April 17, he determined that "lift my hand against my own State and people is impossible." After resigning from the U.S. Army, he assumed command of Virginia's forces on April 23. His military genius came to the forefront after he was given command of the Army of Northern Virginia in June 1862, and despite being consistently outnumbered, he led his forces in a series of remarkable victories that included Second Manassas, Second Bull Run, Fredericksburg, and Chancellorsville. The Battle of Gettysburg in July 1863 marked his last major campaign on Northern soil. Remaining thereafter in Virginia, he mounted skillful defenses against the Union's Overland Campaign and the siege of Petersburg from spring 1864 to spring 1865. After Petersburg and Richmond fell, he surrendered to General Ulysses S. Grant at Appomattox Court House on April 9, 1865. Later that year, he accepted the presidency of Washington College, now Washington and Lee University, in Lexington, Virginia, and retained that position until his death on October 12, 1870.