Input (grade 8): Union Maj. Gen. George Gordon Meade's Army of the Potomac defeated attacks by Confederate Gen. Robert E. Lee's Army of Northern Virginia, ending Lee's invasion of the North.
Output (grade 9): The battle took place between the Confederate Army of Northern Virginia, commanded by General Robert E. Lee, and the Union Army of the Potomac, commanded by General George Meade.