Here is what we know so far about the shooting, the gunman and the victims.

The gunman and all of the victims were students

The police said Mr. Berhow went to the school on Thursday morning, pulled a handgun from a backpack and shot five people before shooting himself in the head. Thursday was his birthday, the police said.

Officials said the shooting victims were all students and appeared to be randomly targeted by the gunman.

Two of the students were killed, while three were injured by gunfire, the police said.

The students who died were a 15-year-old girl and a 14-year-old boy, the authorities said. On Friday, the police identified the girl as Gracie Anne Muehlberger. Her father said in a brief phone interview that the family was grieving.

The injured victims, who law enforcement officials said were all in stable condition as of Thursday night, were a 14-year-old girl, a 15-year-old girl and a 14-year-old boy.