According to the law of conservation energy: "Energy can neither be created nor is it destroyed. It can only be…