OAKLAND — An attempted robbery gone bad in East Oakland on Wednesday resulted in a gunfight that left the suspect dead and the intended victim also wounded, authorities said Thursday.

The man killed was identified by police as Nakia Polk, 20, of Oakland.

The name of the 18-year-old man who was wounded was not released. He was shot multiple times and remains hospitalized.

The shooting happened about 2:18 p.m. in the 2600 block of 23rd Avenue.

Police said that according to witnesses, Polk confronted the victim on the street, pointed a gun at him and tried to rob him.

When the younger man resisted he was shot but was still able to pull a gun and fire back, hitting Polk, Sgt. Michael Cardoza said.

Polk was able to run a short distance before collapsing. He was pronounced dead at the scene. The 18-year-old was taken by ambulance to a hospital.

Police said the 18-year-old had a gun with him because he has been robbed before. The two men did not know each other, authorities said.

Police are continuing to investigate the shooting.