On the final day of six weeks of hearings into the deaths of 30 Britons at a seaside resort in Sousse, Tunisia, Judge Nicholas Loraine-Smith condemned the reaction of Tunisian police when an Islamist gunman, Seifeddine Rezgui, began shooting at the Riu Imperial Marhaba Hotel: “Their response could and should have been effective.”

The inquests heard that police were slow to respond, with some officers fainting or running away.

The Coroner is delivering his conclusions at the end of the inquests into the deaths of 30 British tourists during the attack on 26 June 2015.

He told the bereaved families: “Throughout the proceedings, you have shown a quiet dignity for which your loved ones would have been extremely proud.”

Judge Nicholas Loraine-Smith said: “Unarmed guards could not have done much against a terrorist with a Kalashnikov and grenades.

“Had the attack been seen on CCTV, it might have been identified sooner but not much sooner.

“The attack was so unexpected and sudden that I cannot say that if an emergency evacuation procedure had been carried out, it would have been effective.

“The one security measure that may have made a difference was having an armed guard. Having reviewed the gun law in Tunisia, it is clear that was not a realistic option.”

During the inquests, several families of the victims have said that their relatives would not have gone to Tunisia if they had been told of the Foreign Office warnings after the Bardo Museum attack in March 2015.