(KRON) — A man was arrested on Tuesday in connection with two homicides that happened outside a San Leandro gym, the San Leandro Police Department said. The killings happened on Sept. 14 and Sept. 24 outside 24-Hour Fitness Bayfair, located at 304 Bayfair Mall.

In both cases, SLPD was called to the gym in the late morning for an unconscious man inside a vehicle in the parking lot. Both times, police found a dead man with a gunshot wound.

“We understand this case garnered a lot of community attention and generated an understandably high level of concern for safety, particularly at 24-Hour Fitness Bayfair,” said SLPD Lieutenant Abe Teng.

Police reviewed surveillance footage, and in both instances, they saw a man who arrived at the scene in work boots. During the first killing, he wore a red Nike backpack. He took the same route when leaving the scene both times and was identified as a suspect.

On Tuesday just after 2 p.m., an SLPD officer saw a man wearing black work boots and a red Nike backpack in the area of Hesperian Boulevard and Halcyon Drive. The suspect took a route across this intersection when leaving the scene after the homicides.

The man, later identified as 23-year-old Joshua Ballard of San Leandro, was detained. He had a semiautomatic handgun when he was arrested.

Police served a search warrant at Ballard’s home and found more evidence connecting him to the homicides. Police said the victims were not specifically targeted and the crimes were not directly related to 24-Hour Fitness.

The Alameda County District Attorney’s Office charged Ballard with two counts of murder, attempted carjacking, robbery, assault with a firearm and other weapons violations.

Alameda County DA Pamela Price issued the following statement regarding the arrest:

“This arrest marks a significant development in our ongoing effort to combat gun violence, robberies and carjackings in our community. We thank the San Leandro police department for its investigative work and arresting a suspect they believe was attempting to rob and carjack random victims. My office is committed to safeguarding our community and to ensure those responsible for violent acts are swiftly brought to justice. No one accused of committing gun violence in our community gets a free pass from being prosecuted by the Alameda County District Attorney’s Office.”

SLPD urges anyone with information to call (510) 577-3244, or submit an anonymous tip at (510) 577-3278, or text a tip to 888777 and use the keyword “TipSLPolice.”