BUT SCHOOL SHOOTINGS WERE UNKNOWN: Flashback: When toting guns in high school was cool.

New York City high schoolers used to pack heat as often as they packed lunch.

This month, more than 100,000 city public school kids walked out to protest gun violence — but last century some students attended class armed with their rifles and practiced shooting on school grounds.

Many of the city’s public high schools had shooting clubs and a few even had gun ranges on their premises, according to accounts from the Department of Education and others.

There were at least three shooting ranges in public schools, the DOE said, including Curtis HS on Staten Island and Erasmus Hall HS in Brooklyn.

Another inside Far Rockaway HS in Queens, which closed in 2011, is shown in a black-and-white archival photo from May 1929 displaying a compartmentalized gun range with at least five windows to shoot from and cranks for students to pull the targets back and forth.

“To accommodate the kids, they even made them these little pull-out benches they can kneel on to shoot from that position or even lie down to shoot,” said Darren Leung, owner of Westside Rifle & Pistol Range in Chelsea, describing the equipment seen in the 89-year-old photo. “What an excellent design.”

Shooting clubs were popular in many schools, even if they didn’t have gun ranges.

A different, and in many ways better, America.