A 20-year-old Buffalo man faces a lengthy prison sentence after admitting to robbing a man at gunpoint and then minutes later forcing himself sexually on a woman last November, the Erie County District Attorney’s Office announced Tuesday.

Jesse Buchanan, of Woltz Avenue, pleaded guilty to first-degree robbery and first-degree criminal sexual act before Erie County Judge Kenneth F. Case, according to District Attorney Frank A. Sedita III.

Buchanan was linked to the crimes by DNA evidence.

Buchanan admitted robbing the man near East Delavan Avenue and Suffolk Street and then committing the sex crime about a block away.

Buchanan faces a maximum prison sentence of 25 years on each count when sentenced Nov. 7 by the judge.