Pastor killed by demon-possessed person

It is trending news in one of our neighbouring countries (name withheld) that a pastor, known for his supernatural abilities, was tragically killed by a young man who was allegedly possessed by a demon. Witnesses claim the suspect exhibited erratic behaviour, speaking in unknown tongues and displaying uncontrollable aggression before fatally attacking the pastor during an exorcism session. This young man is now facing charges for murder. I wonder whether this young man should be held fully accountable for the killing, considering it was not he but the demons. What does Tanzanian law say about this? Please enlighten me.
SB, Dar es Salaam 

This is a tragic story that raises questions about criminal responsibility and defences against criminal liability. It is an offence to cause the death of another person in Tanzania. Under Section 196 of the Penal Code, Cap. 16 [R.E 2022] (Penal Code), any person who, with malice aforethought, causes the death of another person by an unlawful act or omission is guilty of murder. Malice aforethought is simply the intention to kill, which distinguishes murder from manslaughter (killing without intent) and has been described in various caselaw.

To eliminate liability for killing a person, one may consider the defence of insanity. Section 13(1) of the Penal Code provides that a person shall not be criminally responsible for an act or omission if, at the time of doing the act or making the omission, he is through any disease affecting his mind: (a) incapable of understanding what he is doing; (b) incapable of appreciating that he ought not to do the act or omission; or (c) does not have control of the act or omission. However, section 13(2) of the Penal Code states that a person may be criminally responsible for an act or omission, although his mind is affected by disease, if such disease does not, in fact, produce upon his mind one or the other of the effects referred to in Section 13(1) regarding that act or omission. Therefore, if the accused was suffering from a mental disorder at the time of the crime and was incapable of understanding the nature of his actions, he may be declared not guilty by reason of insanity.

Now, your scenario describes demon possession, which we must admit we are not experts in. Nonetheless, from our legal practice and experience in such scenarios, the defence may seek the opinion of a medical and psychological expert to argue that the suspect was suffering from an acute episode of mental disorder at the time of the incident. Of course, the prosecution will rebut this argument and try to demonstrate that the attack was deliberate and should be treated as murder under Section 196 of the Penal Code. After hearing the arguments from both sides, the Court must determine whether the accused was truly unable to form the intent to murder due to mental incapacity during the incident. Expert testimony from medical professionals, the nature of the attack, and the accused’s past psychiatric records will play a crucial role in the court’s decision. If the defence successfully proves insanity, the suspect may receive medical treatment instead of a sentence. However, if the Court finds no sufficient evidence of mental incapacity, the accused could be convicted of murder and face the full penalty under section 196, which unfortunately is death. Your lawyer can provide further clarification.