Khairi Saadallah, 26, murdered history teacher James Furlong, 36, scientist David Wails, 49, and US citizen Joseph Ritchie-Bennett, 39, in savage violence that lasted less than a minute this summer.
The victims had all been enjoying the sunshine in Forbury Gardens, Reading during the first Covid-19 lockdown when they were attacked. Stephen Young, and Patrick Edwards and Nishit Nisudan were also stabbed by Saadallah but survived.
Saadallah, who shouted “Allahu Akhbar” during the stabbing spree, pleaded guilty to the murders in November.
Prosecutors say the killings were a terror attack, but Sadallah has denied being motivated by an ideological cause or any substantial preparation before the murders.
A sentencing heard on Tuesday heard that Saadallah had come to the UK from the Libyan capital Tripoli in 2012 but was refused asylum.
Despite his immigration status and a series of criminal convictions, Saadallah managed to remain in the UK for years until he carried out the attack.
He had been set free from prison fifteen days before the murders and once again earmarked for deportation but he could not be removed due to the unstable situation in Libya, the court heard.
Describing the “brutal” attack on June 20 last year, prosecutor Alison Morgan QC said: “In less than a minute, shouting the words Allahu Akhbar – God is greatest – the defendant carried out a lethal attack with a knife, killing all three men before they had even a chance to respond and try to defend themselves.
“Within the same minute, the defendant went on to attack others nearby, stabbing three more men.
“The defendant was ruthlessly efficient in his actions and, the prosecution’s case is, the attack perpetrated by him was carefully planned and executed with determination and precision.
“Moreover the defendant believed in carrying out this attack he was acting in pursuit of an extremist ideology he appears to have held for some time.
“He believed killing as many people as possible, he was performing an act of religious jihad.”
Ms Morgan suggested to the court Mr Justice Sweeney could considered imposing a whole life prison term on Saadallah.
The court heard Saadallah came to the UK initially on a visitor’s visa, and then made an asylum claim on the basis he had fled from a militia that had helped to overthrow Colonel Gaddafi.
“He maintained he had been arrested in Libya and imprisoned for one day, accused of being a traitor by revolutionary rebels”, said Ms Morgan.
“He said he had been classified as a traitor for refusing to torture people.”
The prosecutor said Saadallah had been part of Ansar Al Sharia – now a proscribed terrorist organisation – but he denied using weapons or fighting in his asylum interview, claiming instead he had been “helping them and just guarding some hospitals”.
But Ms Morgan said 2011 Facebook photos showed Saadallah posing with weapons: “The defendant was involved in military activities, showing him not to have been reluctant or somehow rather fearful of involvement, but proud of what he was doing”.
Saadallah “absconded” in 2013 after his failed asylum bid but was back on the radar of British authorities due to his criminal offending, the court heard.
He agreed to leave the UK voluntarily but instead remained in the country, and then “stopped cooperating with the process in 2014”.
Ms Morgan said Saadallah also met Omar Brooks, a convicted terror offender and associate of hate preacher Anjem Choudary, while in prison, attending prayers and gym sessions together.
Saadallah was given temporary leave to remain in the UK until 2023, the court heard, but a Home Office review prompted by his criminal offending in 2019 led to him being earmarked for possible deportation.
“He was notified the Secretary of State had determined deportation was in the public good”, said the prosecutor.
“But he was told the Secretary of State was not going to take the step of deporting the defendant at that time because of what was described as a legal barrier. The legal barrier that prevented him from being deported was purely and simply the circumstances as they existed in Libya at that time.”
Saadallah was released from his latest prison spell on June 5, 2020, and had been engaged with mental health services, the court heard.
The sentencing hearing, which is due to last up to three days, continues.