Finals week was dangerous for Thomas Saenz.

The Navy lieutenant needed armed guards and an armored car to get to an exam site, in Kabul, Afghanistan. A deadly bomb attack also caused him to his miss classes — transmitted live via the Internet — but he persevered and earned a master’s degree in engineering from the University of Southern California while commanding a top security team.

His class graduated Friday, as he joins a growing number of service members earning college degrees while deployed in a war zone.

“Not only was he out there living on the edge, but he had to get his homework done,” USC professor Frank Alvidrez said.

The Obama administration is pushing universities to find creative ways to help service members complete their degrees as it tracks the success of its post 9/11 GI Bill, which is designed to be the most comprehensive education benefit for veterans since World War II.

Enrollments for the new GI Bill number more than 480,000, according to the Veteran’s Administration, which is starting to track the number of graduates.

It’s not known just how many others like Saenz earn their degrees while in combat. A commencement ceremony for 100 war-zone graduates from various universities is planned in late May in Kandahar.

“They really are multitasking in the extreme,” said Bob Ludwig, spokesman for the University of Maryland University College, adding that the coursework can provide relief from the mental turmoil of war. “It really is an opportunity to step away from the battlefield and have sort of the safety of being in a classroom.”

UMUC has about 30,000 active-duty service members among its students and was among the first schools to send faculty to Iraq to teach troops in 2008 during the war. UMUC also has adjunct professors giving classes in tents in remote outposts of Afghanistan as well as online instruction on bases.

Saenz, a 33-year-old father of two, used the GI Bill to enroll at USC, but midway through his studies the Navy pilot was called to be deployed to Afghanistan.

After getting approval from his professors and Navy commanders, Saenz spent his final year of studies racing to his computer on base at 5 a.m. to attend the live transmission of his classes before dedicating his day to overseeing security for top generals and then-Secretary of Defense Leon Panetta.

He missed a class that required his online presence when a suicide bomber blew himself up near NATO’s headquarters in Kabul, killing six civilians.

The base was locked down. Saenz wrote to his professor and aide when the Internet was back up to explain his absence.

“I was worried because it was early in the semester and I was afraid it would affect my grade,” he said. “But they were real supportive.”

Another time, he was absent because he was arranging for a helicopter to transport Army Gen. Martin Dempsey, chairman of the Joint Chiefs of Staff. Saenz caught up by watching the recorded classes.

“I told my class if Thomas can get his homework done on time then I don’t think there are any excuses for the rest of you all,” Alvidrez said. “And he pulled an ‘A.’ He was one of the top 10 percent.”

Even getting to finals was treacherous. After military officials checked intelligence to ensure there were no imminent threats, he crossed Kabul on a highly dangerous road with armed guards in an armored SUV to the Army base where a military official was certified to give him the university exams. While there, he picked up ammo, weapons and dropped off radios to be repaired, then grabbed some barbeque at a tent.