It was the second time in less than two months that Daniel Iftikhar - who had no previous convictions - had hit somebody with a hammer, a judge heard.
The 18-year-old, who carried the weapon for "self defence," saw the youth in Wolverhampton after completing the last of his first-year exams at the city's university, Wolverhampton Crown Court was told.
The 17-year-old victim had argued with Iftikhar's mother the previous day, revealed Mr Robert Price, prosecuting.
CCTV captured him tailing the target down Dudley Street in the city centre until he paused close to Primark at the Mander Centre entrance at 4.40pm on April 15.
The defendant circled the unsuspecting victim to confirm it was the right person before striding silently towards him and smashing the back of his head with a claw hammer, which he dropped and fled leaving the victim unconscious in the street.
Interactive map shows where attack happened:
Iftikhar's DNA and fingerprints were on the weapon and its carrier bag and he was arrested four days later.
The blow caused a complex skull fracture with fragments of bone damaging the brain of the victim, who underwent emergency surgery and is due to have a titanium plate inserted in his head later this year.
"The attack was out of revenge as a result of his grievance about the way his mother had reportedly been treated," continued the prosecutor.
Second hammer attack
Iftikhar was already under investigation after another hammer attack in Birmingham's New Street Station on February 25 in which he struck 18-year-old Tahir Armani several times after they exchanged words on the concourse. Fortunately on that occasion the injuries were not too serious
The defendant was detained and disarmed at the scene but was then released pending further investigation, allowing him to strike again with a second hammer, the court heard.
Mr Alastair Smith, defending, said Iftikhar was studying for a psychology degree with a "glowing professional future" until the two attacks took place.
The defendant, from Madin Road, Tipton, admitted causing grievous bodily harm with intent, possession of an offensive weapon and assault.
He said in a statement: "I had everything going for me in my life and I have lost it. I will serve a significant period of time in custody that I should have used more productively."
Judge James Burbidge QC sent him into detention for 10 years, with three years extra monitoring on release because of the danger to the public he represents.
The judge said: "Your crimes are unfathomable, without rhyme or reason. They beggar comprehension."