Murrysville, Pennsylvania: When a knife-wielding, black-clad student stormed out of a classroom in the science wing of Franklin Regional High School, instincts kicked in.
In student Brett Hurt's case, according to his friend Gracey Evans, the instinct was to protect.
US stab rampage suspect named
Commentator fired from coaching job
No more iPhone headphone jack?
Deported man 'happy to be back'
Texas mother allegedly guns down her daughters
Clinton pleads for 'common sense gun' reform
Volkswagen settlement to hit $20b
John Oliver takes on Brexit leaders
US stab rampage suspect named
Police name teenager suspected of a stabbing rampage at a U.S. school in which 22 people were wounded.
Brett "has a little sister, and he was protecting me like he would protect her", said Gracey, a resident of Murrysville, Pennsylvania.
Brett blocked the knife-wielder - who authorities later identified as Alex Hribal - from reaching Gracey.
For that, Brett took a knife in the back. According to the Evans family, he was doing well but was expected to remain overnight at Forbes Regional Hospital.
Hribal, 16, was taken into custody after being wrestled to the floor of a school hallway and disarmed by a security guard and a school administrator.
Twenty-four people were injured - at least one of them critically - in the attack on Wednesday, local time.
The youth was taken to the Murrysville police station, where he was questioned by officers and Westmoreland County detectives before being taken to Westmoreland Hospital for minor injuries to his hands.
After he was treated for his cuts, the suspect, dressed in a hospital gown and handcuffed, was returned to the police station.
On Wednesday evening, local time, he was taken before District Judge Charles Conway in Export.
Westmoreland County Sheriff Jonathan Held described Hribal as quiet and said the teen had not talked to authorities since being brought to the judge's office.
Hribal was arraigned on four counts of attempted homicide, 21 counts of aggravated assault and one count of possessing a prohibited weapon on school property.
When tragedy strikes, and notably when the victims are young people, heroes are an important part of the healing process, said Anthony Mannarino, director of the Centre for Traumatic Stress in Children and Adolescents.
"These events are horrific," said Mr Mannarino. "For others to know that their colleagues or their classmates did the right thing or did an important thing to protect others is always uplifting in these terrible situations."
School superintendent Gennaro Piraino said "staff members acted quickly and saved the lives of many students", and students did the same.
Hope Demont said student Nate Scimio jumped in front of three youths who were being attacked. "There were seniors running everywhere trying to see if they could carry someone, help someone," she said.
Ian Griffith, 18, said he saw assistant principal Sam King talking to the perpetrator, who then stabbed a security guard.
Mr King jumped on the student and Mr Griffith said he then jumped on top of the pair. He said he tried to hold down the suspect's hands and arms and Mr King told him to call an ambulance.
Mr Griffith said when he returned other staff members were helping to keep the suspect contained.
"I think Mr King is the real hero," he said.