The court was told the student was on her way home from a night out in the Coventry University area of the city on June 22.

She called a friend as she made her was along down Primrose Hill Street and into Cox Street, and while talking on the phone she was grabbed by Elam. She dropped her phone and tried to fight her attacker off.

But he forced her down a pathway in nearby Grove Street which has no street lighting and pushed her against a wall. During a struggle she lashed out, scratching his face.

He let go of her as a car pulled up after its driver had heard screams. The driver followed Elam for a few moments as he ran towards Pool Meadow before returning to the victim.

The young woman, who had bruising and grazing, was taken to Coventry police station where DNA analysis from her nail clippings showed blood under her nails was Elam's.

Gareth Walters, prosecuting, said CCTV cameras showed Elam had left home at 2.40am in the morning and had walked across to the other side of the city centre to the area where the attack took place before returning home just under an hour later.

When he was first arrested he claimed he had walked round looking for cigarette butts and did not meet any female.

But in a second interview, faced with the DNA evidence, he said he remembered he had had a cut to the side of his mouth, but did not know how he had got it.

Matthew Barnes, defending, told the court: "This was completely out of character."

"We're talking about microscopic skin cells found under the victim's nails, but that's all we needed to get a positive DNA result pointing to Elam as the prime suspect.

"He initially admitted sexual assault but we felt the seriousness of the attack warranted a stronger charge of attempted rape and that's what we pushed for and the evidence we secured against him eventually gave Elam little option but to plead guilty.

"He has received a lengthy custodial sentence and placed on the sex offenders' register for life that means he'll be monitored by police sex offender managers and live under strict conditions in order to protect the public."