Two teens were charged Friday in connection with a pellet gun shooting that injured two students at a Chantilly middle school on June 15, Fairfax County police said.

The 16-year-olds from Fairfax County face serious charges that could result in lengthy sentences if convicted in the incident that occurred on the last day of school at Rocky Run Middle School.

One teen was charged with two counts of malicious wounding, while the other faces one count of malicious wounding and one count of shooting into an unoccupied building, police said. Sentences for malicious wounding can range from five to 20 years in detention.

The shooting occurred around 10 a.m. on June 15, as students were gathered outside the school for an end of the year activity, police and school officials said.

A 14-year-old male student reported he had been shot in the stomach, according to a search warrant filed in Fairfax County court. A short time later, a 13-year-old female student reported a sharp pain in her back and fell to the ground, according to the search warrant.

The girl felt blood running down her leg and teachers came to her assistance, according to the search warrant. Both students were transported to the hospital for treatment, police said.

A witness at the scene told a school resource officer he saw three people in white shirts run into a house near the scene of the shooting, according to a search warrant.

Police later located the teens during a canvass of the neighborhood. In an interview with police, one of the teens, a student at Chantilly High School, admitted he and a friend had committed the shooting, according to the search warrant.

A pellet gun was also recovered at the scene, police said.

The Post generally does not name juveniles accused of crimes.

More from The Washington Post:

Va. Tech victims’ families to join anti-violence rally

Police standoff with armed man in Falls Church

Md. executive convicted in biodiesel scam

Read moreThe Post’s crime coverage