PARKLAND, Fla. (AP) — President Joe Biden, in a surprise video address to a Tuesday commencement ceremony, said graduating seniors who were freshmen when a mass shooting left 17 people dead at their Florida high school have turned pain into purpose and darkness into light.

Besides surviving the most deadly high school shooting in U.S. history, Biden also noted that the students graduating this year from Marjory Stoneman Douglas High School in Parkland had their academic careers further disrupted by COVID-19.

The video was recorded in the East Room of the White House and played at the ceremony in South Florida.

“Three years ago, your lives and the lives of this community changed in an instant,” Biden told the graduates in the recording. “This class lost a piece of its soul. You’ve been tested in ways no young person should ever have to face –- from a freshman year, a year of unspeakable loss, to a junior and senior year upended by a pandemic.”

Of those killed in the February 2018 shooting, 14 were students and three were staff members. Nine of those students would have graduated with the Class of 2021. Instead, their parents were set to receive their diplomas.

Former Stoneman Douglas student Nikolas Cruz, 22, faces the death penalty if convicted of the killings. His lawyers have said he would plead guilty in exchange for a life prison sentence, but prosecutors have rejected that.