The victim was hit about 3:30 p.m. Thursday outside the recreation center at 201 N St. SW, police said.
He was taken to a local hospital. Authorities found numerous shell casings and a weapon near the recreation center, where glass was shattered by the shots.
The center closed after the shooting, a D.C. Department of Parks and Recreation spokesman said. The building reopened Friday morning.
Authorities didn’t have any information about the shooter.
Violent crime is down this year in Police Service Area 105, where the shooting occurred. District crime statistics show 20 violent crimes in the area from January 1 to May 7, compared with 27 crimes in the same period the previous year.
But the PSA has had more assaults with guns so far this year. The area had five assaults with guns from January 1 to May 7, compared to four assaults in the same period the previous year.