Gregg L. Hagerty was in the middle of a summer school class in Fairfax County yesterday when an Army helicopter swept down from the sky, fired shots and dropped bombs 20 yards from where he sat.

It didn't faze him a bit.

"I've seen most of it before," said the 22-year-old second lieutenant who graduated from West Point in May.

He and 300 classmates at Fort Belvoir were watching a war unfold before their eyes yesterday during a semiannual simulated combat and bridge building demonstration that was part of the basic training program for the Army Corps of Engineers.

Despite loud cheering throughout the mock battle and hundreds of civilian spectators, officials said "Operation Pontontier" is primarily educational.

"The primary purpose is to teach the new officers," said Marilu A. Trainor, deputy public affairs officer. "We just invite everybody else."

The simulated battle, which saw a team of soldiers in camouflaged jumpsuits make their mock escape onto the Potomac River in a rubber raft, centered on the various bridging operations that could be brought into actual combat by the Corps of Engineers.

The students, who have already received basic military instruction in college, are trained at Fort Belvoir to be military engineers.

"We can take somebody who studied English or history in college and make an engineer out of them," said Capt. Marcus H. Sachs, an instructor.

The 17-week program includes some of the technical information that civilian engineers learn, but along with the classroom instruction, Fort Belvoir teaches road construction, antitank warfare, mine installation and demolitions.

"People think of engineers as nerds who carry slide rules," one student said, as he flexed his biceps. "We're different."

"This is part of the culmination of bridge training for them," Sachs said of yesterday's events. "They can see people {building bridges} who really know what they are doing."

Sachs said building bridges has been a critical part of military operations since Julius Caesar's invasion of Germany across the Rhine River in 52 B.C.

The bridge and combat demonstrations have been staged about six times a year for the last decade, Fort Belvoir officials said, but in the next few years all instruction will be moved to more spacious facilities at Fort Leonard Wood in Missouri.

"It's difficult to take them out and teach them demolitions in the middle of Fairfax County," Trainor said. "There's more room out in Missouri."

Being close to residential neighborhoods has resulted in some angry and frightened phone calls over the years, Trainor said, but "the neighbors really cooperate."

As the smoke curled upward at the end of the mock battle, members of the 15th Regiment New York Volunteer Engineers, complete with wooden rifles and wearing authentically copied wool uniforms, simulated bridge construction as it was during the Civil War. The group's primitive technology drew jeers from the students.

"It'll take them four years to build a bridge," one said.