A torrential thunderstorm deluged portions of Montgomery and Prince George's counties last night, flooding basements, stalling cars, forcing several road closings and bringing as much as four inches of rain in a few hours.

Along many roads in both counties, motorists abandoned their halted vehicles, and struggled to higher ground through waters that swirled around their knees, and sometimes up to their waists, authorities reported.

Within minutes after the storm struck, Sligo Creek overflowed its banks and rapidly rising water sluiced across Sligo Creek Parkway near New Hampshire Avenue in Prince George's County. About three miles of the parkway were closed for a time, and a smaller section, where the churning waters ripped out guardrails, remained closed late last night.

Sgt. Joseph Schwartz of the Maryland National Capital Park Police said officers from his department helped some motorists escape from cars stalled on the parkway.

A mile-long strip of Georgia Avenue south of the Capital Beltway was also closed, and high water was reported for a time on Lanham Severn Road, Greenbelt Road, and a small area around Interstate 95 and the Beltway.

Although the storm was reported heaviest in Maryland, where it remained stalled for a time and poured a measured four inches on Bowie, rain also fell in other parts of the area. Fairfax County Police reported three separate collisions, involving a total of eight cars and 15 persons, on I-95 near Lorton during a downpour about 7:45 p.m. No serious injuries were reported.

National Weather Service forecaster Harold Hess said the threat of additional thunderstorms will persist through Tuesday.