Parents who have to deal with bored children, or worse, summertime childcare arrangements, jump at the idea of summer camp if they can afford it. Surely it would be good experience for the children, too. However, the first summer camp wasn't for the benefit of the children nor for the parents- it was for the good of the United States. It happened when Frederick Gunn, who ran a boarding school in Connecticut, marched a few dozen of his students 42 miles to camp on the beach of Long Island Sound and trained them for military service. That was in 1861, and it was possible that those children would grow up to fight for the Union.
The idea caught on, and later camps were set up to give poor urban children a taste of the great outdoors away from their factory jobs, and give a taste of self-sufficiency to pampered children from rich families. Along with wilderness skills, military drills and weapons training were a part of the camp experience until after World War II. Read up on the history of summer camp at Atlas Obscura.
The history of the summer camp for children is part of a continuing series of articles Atlas Obscura is doing about summer camp. You can see them all here.