Mother Elizabeth Acevedo and her son Andres, 3, wait for news of her son Jose an eight-grader student at the Belmont High School in Los Angeles Thursday, Feb. 1, 2018. Two students were shot and wounded, one critically, inside a Los Angeles middle school classroom Thursday morning and police arrested a female student suspect, authorities said. (Damian Dovarganes)

Gloria Echeverria watches as Los Angeles police officers close off a street where a shooting occurred at a middle school in Los Angeles on Thursday, Feb. 1, 2018. Two students were shot inside the middle school classroom Thursday morning and police arrested a female student suspect, authorities said. (AP Photo/Amanda Lee Myers)

Sound

The gallery will resume inseconds

Parents wait for news of students at the Belmont High School in Los Angeles Thursday, Feb. 1, 2018. Two students were shot and wounded, one critically, inside a Los Angeles middle school classroom Thursday morning and police arrested a female student suspect, authorities said. (Damian Dovarganes)

Los Angeles Policecordon off the Belmont High School in Los Angeles Thursday, Feb. 1, 2018. Two students were shot and wounded, one critically, inside a Los Angeles middle school classroom Thursday morning and police arrested a female student suspect, authorities said. (AP Photo/Damian Dovarganes)

A Los Angeles police school officer walks under yellow tape at the Salvador B. Castro Middle School near downtown Los Angeles Thursday, Feb. 1, 2018. Students at the Los Angeles middle school have been reunited with their parents after a shooting that left a teen critically wounded and several other children injured. (AP Photo/Damian Dovarganes)

The girl was taken into custody minutes after the shooting. TV video from helicopters showed a dark-haired girl in a sweatshirt being led from the school in handcuffs as anxious parents and family members gathered on a street corner, many crying and talking on their phones as they waited.

Police interviewed the girl and agreed it was an accident. On Thursday evening, long hours after chaos and panic had subsided, the girl was booked into Juvenile Hall on suspicion of negligently discharging a firearm on school grounds.

Police haven’t said from where the girl got the semi-automatic handgun or why she brought it to the downtown campus.

Five people were injured in the shooting. The most seriously hurt was a 15-year-old boy who was shot in the head but doctors said the bullet didn’t hit anything vital or life-threatening.

“This child was extremely lucky,” said Dr. Aaron Strumwasser at Los Angeles County-USC Medical Center. “I think he will do fine … I anticipate he’ll make a full recovery.”

A 15-year-old girl was shot in the wrist but Strumwasser said the injury was minor.

Three other people had minor face or head injuries, some from broken glass, but weren’t shot, officials said.

An 11-year-old boy and a 12-year-old girl were treated at the hospital and released while a 30-year-old woman who is a school staff member had only minor injuries, Los Angeles city police said in a statement.

Shallin Lopez, a seventh-grader, was in the room at the time of the shooting. She said she never saw a gun.

“I just saw something pop,” she said. “It was loud. I didn’t see her shoot.”

Jordan Valenzuela, the 12-year-old student who was next door, told The Associated Press by telephone that after her heard the gunshot and screaming, children in the other classroom started banging on the door connecting the two rooms.

He and some other children opened it and began trying to help the victims. Jordan said he noticed his friend sitting at her desk with her hands covering her face.

Jordan said later, the girl asked him to hide the backpack with the gun in it.

“I said ‘No,'” he said. “Then I moved away from her because I was a little bit scared.”

But, he said, “she doesn’t do bad things, she just stays quiet.”

The campus was locked down but later most classes continued, although parents were permitted to take their children home early if they wished.

The shooting left parents shaken.

Claudia Anzueto, Jordan Valenzuela’s mother, said the boy was crying when he called her from a borrowed cellphone to tell her he was OK.

“Not safe, very insecure,” Anzueto said of the school. “I fear for my son’s life. You know what I mean, you really hear about things like this in the news, and just to hear that something like that happened so close to home, it scared the life out of me.”

Most weapons “that our young people get their hands on” come from their homes or those of other family members, Los Angeles School Police Department Chief Steve Zipperman said.

It wasn’t immediately clear how she managed to bring it into class, he said.

The district has a policy requiring every middle and high school campus to conduct daily random searches by metal-detector wands at different hours of the school day for students in the sixth grade and up.

Student Melanie Valencia, 13, said the school did a random security search Thursday, but that she’s never been checked.

Some officials used the shooting to call for gun safety legislation and others said it should give gun owners pause.

“This is a very important call to action to every adult in our community who has a gun,” City Attorney Mike Feuer said. “You must store it safely and keep it out of access for any child to reach. It could result in a tragedy.”