Caleb Sharpe, who previously pleaded guilty to killing one of his former classmates and shooting three other students at Freeman High School in Rockford, Washington, in 2017, was sentenced to 40 years in prison Friday.

Sharpe, 20, who was 15 years old at the time of the shooting, spoke publicly for the first time in five years, apologizing for his actions before he was sentenced, according to the Spokesman-Review, a newspaper that operates out of Spokane, Washington.

"There’s only really one thing that I can say," Sharpe said, per the newspaper. "And that is, I am sorry."

In January, he pleaded guilty to premeditated murder, three counts of attempted murder, and second-degree assault for the attack that took place on Sept. 13, 2017, FOX 28 of Spokane reported.

FLORIDA MASS SHOOTER NIKOLAS CRUZ WATCHED MUSIC VIDEO ABOUT SCHOOL SHOOTING BEFORE RAMPAGE

Map of Washington

Rockford is in Eastern Washington, south of Spokane.  (AP)

"That day showed me the true cost of evil. Everything that this community had to pay, my own family had to pay," Sharpe added, the newspaper reported. "From that point on and now, evil has no place in my heart."

Friday morning’s court hearing was somber as state prosecutors showed footage from the attack, recorded by the school’s surveillance camera.

The front sign of Freeman High School

The sign for Freeman High School in Rockford, Wash., is seen outside the campus on Sept. 13, 2017.  (AP Photo/Nicholas K. Geranios)

Sharpe and his parents, Ben and Ericka Sharpe, watched as the video showed their son setting down a duffle bag in a hallway before pulling out an AR-15 and shooting several high school students.

Ami Strahan, the mother of Sam Strahan, a 15-year-old who died in the shooting, also watched and was seen covering her face as the video showed her son being shot twice and falling to the ground, the Spokesman reported.

The now deceased 15-year-old confronted Sharpe during the shooting and attempted to stop him.

OFFICIALS: STUDENT KILLED CONFRONTING SHOOTER AT HIGH SCHOOL

Strahan spoke during the court hearing, where she called Sharpe an "evil, hateful human being" and pleaded for Spokane County Superior Court Judge Michael Price to sentence him to the longest possible time behind bars, FOX 28 reported.

Sharpe’s public defender Brooke Foley called for a fixed 20-year sentence, citing his age and immaturity at the time of the shooting.

Foley argued Sharpe should be considered a youthful offender as Washington state law says juveniles are less "culpable" for their crimes, the Spokesman reported.

Seattle, Tacoma, Spokane crime

Washington state.

Foley also urged the judge to consider the remainder of Sharpe’s life and his potential rehabilitation into society, following his sentence.

"His prospects for change and rehabilitation are strong," the public defender argued, per the Spokesman report. "Justice is following the law, despite demands for blood."

SCHOOL SHOOTINGS HIT TWO-DECADE RECORD HIGH IN 2021, ACCORDING TO GOVERNMENT REPORT

In response, Deputy Prosecutor Sharon Hedlund argued a heftier 35-year sentence would be more appropriate given the severity of the crime.

"His obsessive and compulsive tendencies were and are an issue," Hedlund said.

According to the Spokesman, Price said the 35-year recommendation did not go far enough.

Price spoke for over an hour and said Sharpe "slaughtered" his classmates. He also explained Washington state’s legal guidelines before sentencing Sharpe to 40 years behind bars.

CLICK HERE TO GET THE FOX NEWS APP

In the explanation, the judge said Sharpe was sentenced as an adult but did not receive the standard 75 to 90-year sentence due to another Washington law that limited the maximum sentence that could be applied to juveniles.

According to the report, Sharpe can appeal the sentence within the next 30 days.

The Associated Press contributed to this report.